none
Problem with Save Graph in msagl format RRS feed

  • Question

  • Hi All,

    Am using my own code to save Graph in msagl format.
    The graph was saved, but while opening it shows error as " Invalid character in the given encoding. Line 1, position 1 "

    The code i used to save is given below,

     Microsoft.Msagl.GraphViewerGdi.GraphRenderer renderer = new Microsoft.Msagl.GraphViewerGdi.GraphRenderer(gSave);
     renderer.CalculateLayout();
     int width = 1000;                      
                                                 
     Bitmap bitmap = new Bitmap(width, (int)(gSave.Height * (width / gSave.Width)));
     renderer.Render(bitmap);
     bitmap.Save("D:\Sample.msagl");

    Thanks
    Akila
    Thursday, January 28, 2010 9:52 AM

Answers

All replies