问题
I'm working on a code which copies a range content to the clipboard as a picture. It works perfectly well when I use the letters and numbers to describe a range:
Call Worksheets("Traces_condenses").Range("A1:AC35").CopyPicture(xlScreen, xlPicture)
However, when I try to replace it with the range described by cell numbers, it fails with the app-defined or object-defined error (1004):
Call Worksheets("Traces_condenses").Range(Cells(1, 1), Cells(2, 1)).CopyPicture(xlScreen, xlPicture)
Could you please suggest me what I'm doing wrong? Thank you in advance, Jan
来源:https://stackoverflow.com/questions/59193463/copypicture-doesn-work-with-the-cell-range-marked-by-numbers