copy photo

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi

Is there a way to make a macro there copy all photo from one sheet to
another sheet if i don't know how many photos there are

Regards alvin
 
Something like:

Option Explicit
Sub testme()
Dim FWks As Worksheet
Dim TWks As Worksheet
Dim myPict As Picture

Set FWks = Worksheets("sheet1")
Set TWks = Worksheets("sheet2")

For Each myPict In FWks.Pictures
myPict.Copy
TWks.Range(myPict.TopLeftCell.Address(0, 0)).PasteSpecial _
Paste:=xlPasteAll
Next myPict

End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top