Get them XML for the current drawing.

N

news.microsoft.com

Hi,

I want to save a visio document into a SQL table, as an XML document. The
idea being that an end user can use visio to create a workflow
diagramatticly, and then I can read the workflow from the XML, and apply the
workflow in a vb.net application.

Under visio02, the only way I could see to do it, was to save the file as
xml to the local hard disk, then open the XML disk file, and read the XML
document back, saving it into my SQL server.

Is there an object/method now that will just give me the XML without all
that fuss
 
M

Mai-lan [MS]

You can use SolutionXML on a shape or document level (it's in the object
reference for Visio 2002 SR1 and later) to store specific information that
you want to pass through in XML. This works out well in workflow apps that
want to consume workflow information without all the diagrammatic
information that Visio stores in the Visio physical file format (VDX). The
scenario is that the end user diagrams the Visio drawing in Visio, and saves
it to Visio VDX format. (Alternatively, the end user creates the diagram in
the Visio ActiveX control embedded in some other user interface.) You can
put code in VBA for the document, in your COM addin or your custom container
code that stores whatever information you care about in the document in
SolutionXML. SolutionXML is persisted in the file format. It is then easy to
write a parser that extracts the SolutionXML (which is just data) from the
Visio VDX document to store in your database.

Hope that helps,
Mai-lan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top