Logo 
Search:

MS Office Forum

Ask Question   UnAnswered
Home » Forum » MS Office       RSS Feeds

Copy & Paste ( pictured image ) ?

  Asked By: Abarrane    Date: Feb 11    Category: MS Office    Views: 880
  

I have an Excel(w/VBA) application where I do a copy&paste;
a range data area as a picture image-(CopyAsPicture).

"Sheet1" is a hidden sheet.
Currently I do this:
Application.Screenupdating=False
Sheets("Sheet1").Activate
Sheets("Sheet1").Range("A1:H20").Select
Copy this selected area.
Sheets("Chart1").Activate
Paste this selected area to Chart1.

Is there any method ( perhaps with objects ),
to do the copy&paste without having to do the
Sheets("Sheet1").Activate &
Sheets("Chart1").Activate
to move the data to Chart1 ?

Share: 

 

1 Answer Found

 
Answer #1    Answered By: Adelino Fischer     Answered On: Feb 11

Try this.

Sub Macro1()
Sheets("Sheet1").Range("A1:H20").CopyPicture
Sheets("Chart1").Paste
End Sub

 
Didn't find what you were looking for? Find more on Copy & Paste ( pictured image ) ? Or get search suggestion and latest updates.




Tagged: