Visio Guy

Visio Guy Website & General Stuff => Visio Marketplace & Classified Ads => Topic started by: Saira Riaz on July 12, 2013, 04:45:27 AM

Title: Advanced .NET Alternate to The MS Visio Object Model
Post by: Saira Riaz on July 12, 2013, 04:45:27 AM
Microsoft Visio is an advanced diagram software by Microsoft which is used by many professionals around the world to create diagrams using available vector graphics. Visio offers many tools to help you draw diagrams, shapes, fill color and add text, among other tasks. Visio makes it easy to build diagrams, graphs, shapes, organization charts and enhance these to meet your specific business needs. You can create a data-linked diagram connected to your key business indicators and make sure the information in your diagrams or chart is always current. Visio organization charts are simple and easy to make or replicate. In this modern digital world, there are several tools and software components being used as an alternative to Visio object model. Thus to perform an advanced level of manipulation, conversion and exporting of diagrams, the most commonly used programming language (.NET) is easily emphasized and relied on.

Recently, I have worked with many such components and found an efficient solution for .NET developers, designed by Aspose. It is known in the software market as Aspose.Diagram ( and it is a class library for working with Microsoft Visio files as an advanced alternate. It allows developers to work with VSD, VSDX, VSS, VST, VSX, VTX, VDW and VDX files on C#, VB.NET, ASP.NET web applications, web services, Mono and Windows applications. It allows you to open files, create and manipulate the elements of the Visio diagram as well as shapes and then export to many file formats. The most commonly supported formats are VDX, VSX, VTX, XPS, HTML, SVG, SWF, image file and PDF. The class library is an effective alternate to Microsoft Visio and provides a better performance to the developers.

Aspose.Diagram is aimed at developers who need to work with Visio files from within their own applications. It allows developers to manipulate the file format quickly and easily, saving time and effort in developing a solution for working with Visio files. Aspose.Diagram makes it easier to manipulate diagrams and convert files into other formats. It makes use of the advanced functionality of Visio Services to manipulate Visio documents on a server. It also uses the advanced functionality provided by Visio Services to manipulate Visio documents on the server. The API is extensible, easy to use and extremely comprehensive. It provides common functionality so that developers have to write less code when performing common tasks such as create or export a diagram. Following are the coding examples in C#:

Create a Diagram

To create a new diagram, use the Diagram class' default constructor.

Diagram diagram = new Diagram();
diagram.Save("Diagram1.vdx", SaveFileFormat.VDX);

Export a Diagram to PDF

Developers can easily export a diagram by using the Diagram class' constructor to read the diagram files and the Save method to export the diagram to any supported image format. To export VSD diagram to PDF:

//Call the diagram constructor to load diagram from a VSD file
Diagram diagram = new Diagram("D:\\Drawing1.vsd");

MemoryStream pdfStream = new MemoryStream();
diagram.Save(pdfStream, SaveFileFormat.PDF);

byte[] pdfContent = pdfStream.GetBuffer();

this.Response.Charset = "UTF-8";
this.Response.ContentEncoding = System.Text.Encoding.UTF8;
this.Response.ContentType = "application/pdf";
this.Response.AppendHeader("Content-Disposition", "attachment; filename=Diagram.pdf");

Aspose.Diagram offers platform independence to the developers whom in turn, can perform many tasks such as read, save, manipulate, export as well as print Visio diagrams from within .NET applications. Efficient and round-the-clock technical support is also available to the developers which makes this component a sought-after alternate to MS Visio object model.