Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Image in Excel
Message
 
To
17/10/2005 21:44:00
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Title:
Miscellaneous
Thread ID:
01059802
Message ID:
01059944
Views:
14
>I managed to insert an image into Excel (from a file on disk), with the .Insert method; now, I want to do additional manipulation. Since this is the only graphic, I simply accessed the first image in the collection of images. I don't have the exact code here right now, for reference, but I got it to work, at any rate.
>
>Now, I was wondering what would happen if I inserted several images, or worked with a previous spreadsheet, which may or may not already have images. How do I get the "handle" of the image I just inserted? If I check for the number of images - I guess it would be something like .Images.Count - and it returns a number "n", is it guaranteed that the next image has the number "n+1"? Or is there a better way to handle this?

Hilmar,

You may reffer to the picture name or/and set the recognizable name. Like:

oExcel.activesheet.pictures(2).Name="MyPicture1_Hello"
lo=oExcel.activesheet.pictures("MyPicture1_Hello")
....
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform