Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Diagram exports (Read 3670 times)
rafaello
YaBB Newbies
*
Offline



Posts: 16
Joined: Jun 23rd, 2009
Diagram exports
Jun 23rd, 2009 at 10:08am
Print Post  
Hi.

I think it would be nice if diagrams could have more export options (to bitmaps etc...). As far as I see the only export option now is a possibility to save diagram as a PDF file. Are some more export options planned for the future?
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Diagram exports
Reply #1 - Jun 23rd, 2009 at 10:43am
Print Post  
Hi,

You can export bitmaps too. Call Diagram.CreateImage() to get a BitmapSource object representing the diagram, create an encoder object (e.g. JpegBitmapEncoder or PngBitmapEncoder) and use its Save method to save the bitmap file.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
rafaello
YaBB Newbies
*
Offline



Posts: 16
Joined: Jun 23rd, 2009
Re: Diagram exports
Reply #2 - Jun 23rd, 2009 at 12:25pm
Print Post  
Hello, me again  Cheesy

Thanks for the solution Stoyan, that one works fine. If I could only suggest more programmer-friendly option for the future: there could be i.e. Diagram.SaveToImage(params) or Diagram.ExportToPdf(params) methods of Diagram's class, but thats only my oppinion  Smiley

Thanks for help once more.
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Diagram exports
Reply #3 - Jul 18th, 2009 at 11:50am
Print Post  
Hi,

We prefer keeping the PDF stuff in a separate assembly, but you know that's what C# extension methods are for (hint, hint Wink).

Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint