Writing Document Summary
VSTO
Below is the code for writing document summary of Visio:
Application.ActiveDocument.Creator = "Zeeshan";
Application.ActiveDocument.Company = "Aspose";
Application.ActiveDocument.Category = "Drawing 2D";
Application.ActiveDocument.Manager = "Self";
Application.ActiveDocument.Title = "Zeeshan";
Application.ActiveDocument.Subject = "Visio Diagram";
Aspose.Diagram
Writing Microsoft Visio Document Summary Info
The DocumentProperties class exposes a number of properties to set or get a Microsoft Visio diagram’s summary information. Aspose.Diagram for .NET can update the drawing summary information and then write the drawing file back to VDX.
To update the drawing summary information of an existing VDX or VSD file:
- Create an instance of the Diagram class.
- Set properties exposed by Diagram.DocumentProps to define the summary information for the Visio drawing file.
- Call the Diagram class' Save method to write the Visio drawing file to VDX.
Check the summary information:
- Open the output VDX file in Microsoft Visio.
- Selecting Info from the File menu.
//Call the diagram constructor to load diagram from a VDX file
Diagram vdxDiagram = new Diagram("Drawing1.vdx");
//Set some summary information about the diagram
vdxDiagram.DocumentProps.Creator = "Ijaz";
vdxDiagram.DocumentProps.Company = "Aspose";
vdxDiagram.DocumentProps.Category = "Drawing 2D";
vdxDiagram.DocumentProps.Manager = "Sergey Polshkov";
vdxDiagram.DocumentProps.Title = "Aspose Title";
vdxDiagram.DocumentProps.TimeCreated = DateTime.Now;
vdxDiagram.DocumentProps.Subject = "Visio Diagram";
vdxDiagram.DocumentProps.Template = "Aspose Template";
//Write the updated file to the disk in VDX file format
vdxDiagram.Save("output.vdx", SaveFileFormat.VDX);