cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Getting Diagram Image like an Object

tunc
Super Contributor

Hi all,
We Developing a mega api(c#) and getting all info from mega.exe. While we gettin diagram path it doesnt enough for us.We want to diagram image object like in the image folder saved .svg format.How could we take just image from mege.exe, not the matching hexaid in image folder?
Thanks.

2 Replies

tunc
Super Contributor

Hi,

We Develop api proejct in c# syntax

in example what is "mydiagram" object type ? and then the other code row block .

Could you convert to c# syntax that code block because of ,many methods or functions doesnt include in c# with same name.

 

Thanks.

gquiniou
Retired

Hi,

 

You can use the "SaveAsPicture" method on a MegaDrawing object.

 

Here is a VB Script example:

Set MyDiagram = GetRoot().getcollection("Diagram").Item(1)
Set MyDrawing = MyDiagram.Drawing("R")
MyDrawing.SaveAsPicture "c:\temp\example2.png", 1, 0, 0, 0, 0, 0