How to save a graph as jpg file in Excel 2007

A

Athena

Hello,

I need to save some Excel Graphs as jpg files. How can I do it?

Thank you.

Athena
 
A

Andy Pope

Hi,

Requires code. Syntax: Activechart.Export <filename> , <filtertype>

You can use this in the immediate window,(ALT+F11 CTRL+G)

Activechart.export "C:\mychart.jpg"

Cheers
Andy
 
A

Athena

Hello Andy,

Thank you very much. It worked. Do you happened to know how to set the
resolution of the jpeg image as well?

Athena
 
J

Jon Peltier

There is no control over the resolution of the exported image. You get
whatever the resolution of the screen is.

By the way, JPG is really the wrong format for a chart. Most computer
graphics are better suited to PNG or GIF, which are also possible using the
Chart.Export method Andy provided. The JPG format was designed for
photographic images, which have areas of gradually changing colors and
shadows. JPG does poorly where there are sharp transitions of colors, for
example, along the edges of shapes and in text. For these situations, which
are what charts are made of, PNG is probably your best choice.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
Peltier Technical Services, Inc. - http://PeltierTech.com
_______


Athena said:
Hello Andy,

Thank you very much. It worked. Do you happened to know how to set the
resolution of the jpeg image as well?

Athena
 
A

Athena

Jon,

Thank you. I did not know this.I shall try to save them as png files.

Athena

Jon Peltier said:
There is no control over the resolution of the exported image. You get
whatever the resolution of the screen is.

By the way, JPG is really the wrong format for a chart. Most computer
graphics are better suited to PNG or GIF, which are also possible using
the Chart.Export method Andy provided. The JPG format was designed for
photographic images, which have areas of gradually changing colors and
shadows. JPG does poorly where there are sharp transitions of colors, for
example, along the edges of shapes and in text. For these situations,
which are what charts are made of, PNG is probably your best choice.

- Jon
 

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

Top