Smrf.NodeXL.ExcelTemplate.TaskPane.ExportToNodeXLGraphGalleryOrEmail C# (CSharp) Method

ExportToNodeXLGraphGalleryOrEmail() protected method

protected ExportToNodeXLGraphGalleryOrEmail ( Form oExportDialog ) : void
oExportDialog System.Windows.Forms.Form
return void
    ExportToNodeXLGraphGalleryOrEmail
    (
        Form oExportDialog
    )
    {
        Debug.Assert(oExportDialog != null);
        AssertValid();

        if (oNodeXLControl.IsLayingOutGraph)
        {
            return;
        }

        if (!this.NonEmptyWorkbookRead)
        {
            FormUtil.ShowWarning(
                "The graph can be exported only after it has been shown.  "
                + HowToShowGraphMessage
                );

            return;
        }

        if (
            oNodeXLControl.ActualWidth <
                GraphExporterUtil.MinimumNodeXLControlWidth
            ||
            oNodeXLControl.ActualHeight <
                GraphExporterUtil.MinimumNodeXLControlHeight
            )
        {
            FormUtil.ShowWarning(
                "The graph pane is too small.  It needs to be enlarged before"
                + " you can export the graph."
                );

            return;
        }

        oExportDialog.ShowDialog();
    }
TaskPane