View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Testing for Screenshot

I doubt if you can test if it is specifically a screen shot. You can test
if it is a picture

? activesheet.pictures.count

I did a paste picture as link (which is what I assume you want to test for)
With the result selected

? typename(selection)
Picture

I verified it was a linked picture as it updated when I changed a cell
linked to the picture. Even so:

? activesheet.shapes(1).Type = msoLinkedPicture
False
? activesheet.shapes(1).type = msoPicture
True

this was in xl97 - looks like a bug or there is another type of linked
picture.

If the picture is linked to another workbook there was no change, except
there is a link shown in Edit=Links.

Maybe someone else has a better way.

--
Regards,
Tom Ogilvy


Tim Childs wrote in message
...
Hi

I want to test for a simple two-part condition:

I want to detect when there is a blank sheet with a screenshot pasted into
it. I can do the first part but how do I detect the second, please?

Thanks

Tim