Is there an image?

  • Thread starter Thread starter MD
  • Start date Start date
M

MD

Hi all,

If in a zone of cells (say a1:e22) contains an imported picture (.jpg), Is
there a way to find out via coding if these cells contain one or more
pictures and if so, print activesheet.

I have a printing routine that prints several pages and I end up printing
the sheet of images but it doesn't always have picture on it.

Regards,

MD
 
for each pic in Activesheet.Pictures
msgbox Pic.TopLeftCell.Address
Next

you could loop through the ranges you want to print and use the intersect
method to see if any of the pictures fall in that range. Note that (oddly
enough), there are more than pictures in the picture collection, but this
should be a start.
 
Simple and efficient!!!.... thx Tom

MD


Tom Ogilvy said:
for each pic in Activesheet.Pictures
msgbox Pic.TopLeftCell.Address
Next

you could loop through the ranges you want to print and use the intersect
method to see if any of the pictures fall in that range. Note that (oddly
enough), there are more than pictures in the picture collection, but this
should be a start.
 

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