Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

SAVE PICTURE IN FILES

2 views
Skip to first unread message

Luca Chiesa

unread,
Jun 19, 2000, 3:00:00 AM6/19/00
to
Hi,
I wish (from VBA) save the images inserted in a excel sheet in files.
I used the object sheet.shapes(i) to retrieve the images but I don't
know
how export the image in a file.

Thaks for the help

Luca


Efstratios Malasiotis

unread,
Jun 20, 2000, 3:00:00 AM6/20/00
to Luca Chiesa
Hi Luca,
There are two-three ways to do that using Excel/VBA:

The easiest would be to add an empty chart-object in your worksheet (press
finish to the chart wizard without any range selection); format the chart
area to transparent or whatever; copy-paste the shape in to the
chart object; export the chart object.

Excel has some built in filters to do that, like:
-------------------------------------------------
Sub expchart()
ActiveChart.Export FileName:="D:\MyChart.gif", FilterName:="GIF"
ActiveChart.Export FileName:="D:\MyChart.jpg", FilterName:="JPEG"
ActiveChart.Export FileName:="D:\MyChart.png", FilterName:="PNG"
End Sub
--------------------------------------------------

HTH
Stratos

0 new messages