Export Diagram Image

2 posts, 0 answers
  1. Paul
    Paul avatar
    12 posts
    Member since:
    Apr 2015

    Posted 04 Nov 2015 Link to this post

    Is it possible to export the whole diagram as an image?

    Image image = this.radDiagram1.ExportToImage(new Size(10000, 5000));
    Clipboard.SetImage(image);

    This only exports the visible area which gives me scrollbars which is not what I need.  I want the entire diagram as an image.

    Thanks

    Paul

     

     

     

  2. Ralitsa
    Admin
    Ralitsa avatar
    176 posts

    Posted 06 Nov 2015 Link to this post

    Hi Paul,

    Thank you for writing us. 

    The method you are using is obsolete as of our latest release. If you want to export the diagram, you can call the ExportToImage method without arguments. All shapes and connections are exported. Please refer to the code snippet below: 
    private void radButton1_Click(object sender, EventArgs e)
    {
        Image image = this.radDiagram1.ExportToImage();
        image.Save(@"..\..\exportedDiagram.bmp");
    }

    In the attachments you can find the sample too. 

    Should you have further questions, I would be glad to help. 

    Regards,
    Ralitsa
    Telerik

  3. UI for WinForms is Visual Studio 2017 Ready
Back to Top