MSChart to bmp/jpeg using C#

girish_d1

New member
Joined
Jul 14, 2003
Messages
2
Hi,
I need to convert an MSChart object to either a BMP or JPEG file. Ive tried converting the MSChart object to a Graphics object using the CreateGraphics() method of the MSChart object, but the bmp thus obtained is an all black image, though the file size is pretty large.
Basically, I need to obtain the MSChart image in a MS Word(.doc) file, programmatically.
Would appreciate any help...
Thanx,
-Girish.
 
The MSChart control has a method which copies its graph to the clipboard as a windows metafile. You should be able to extract that metafile from the clipboard using .NET and save it using the Bitmap classs Save method.
 

Similar threads

Back
Top