The SmartDraw Open API allows you to create extensions that let you skip the drawing process and generate diagrams from data automatically.
You can generate diagrams from data like these:
Build a class diagram from the source code
Show decisions in your project as a decision tree
Visualize relationships in your database
Other diagramming API's, like Visio's for example, require you to specify the coordinates of every shape and line in the diagram.
This makes generating a diagram with code tedious and complex.
The SmartDraw API is very different because it leverages SmartDraw's intelligent formatting engine, the ability to automatically
format and connect shapes on a page based on their relationships.
Using the VisualScript SDK, you can build your own extensions that represent data as a diagram.
You add these applications as Extensions that are incorporated into the user interface. Learn more about Extensions.
The VisualScript SDK provides an object model that allows a developer to build an extension that turns data into diagrams for SmartDraw.
It is the foundation of SmartDraw's Open API. It's easy to use because it leverages SmartDraw's intelligent formatting
to make specifying a tree or a flow as simple as specifying the parents and children. No positioning information is needed because the intelligent formatting engine
knows how to lay them out perfectly on the page.
var vs = new VS.Document(); //Create a new VisualScript document
var theShape= vs.GetTheShape();
var myConnector=theShape.AddShapeConnector(VS.ShapeConnectorTypes.OrgChart); //add the org chart connector to the top shape
myConnector.AddShape(); //add the first shape to the connector
myConnector.AddShape(); //add the second shape to the connector
Without this power it would not be practical to generate the kind of diagrams you need with code.
Learn how to write SmartDraw Extensions using the VisualScript SDK.
Learn the methods for building visuals available in the SDK. Learn how to use the SDK.
Learn how to build diagrams using VisualScript SDK. Learn more.
An overview of all the objects and constants available in the VSON markup language. Learn more.
There are two ways to create an extension in SmartDraw using VisualScript markup.
Generate code and the related UI directly in the SmartDraw app using a built-in editor. Learn more.
Build an end-user UI to access your extension, but generate the script at an external point. Learn more.
©1994-2020 SmartDraw, LLC