save to Visio2002 format using ActiveX drawing control

A

AndrewLLL

Does anybody know a decent way of savving Visio 2003 documents to Visio 2002 format in the Visio ActiveX control? In Microsoft website, it showed these lines:

"You cannot use the SaveAsEx method to save Visio 2003 documents to Visio 2002 format in the Visio ActiveX control. To save a drawing loaded in the Visio drawing control to Visio 2002 format, launch an invisible instance of Visio and call the SaveAsEx method in your Visio application instance, as demonstrated in this Visual Basic 6.0 code that saves a Visio 2003 drawing into the Visio 2003 file format:

Application.Documents(1).SaveAsEx("C:\Documents and Settings" & _
"\myusername\My Documents\Visio2002 file.vsd", visSaveAsWS + _
visSaveAsListInMRU)"

I am confused by this paragraph. Does anybody understand?

What I am thinking is to save a Visio 2003 document into a XML drawing file. In this way, can I load the file correctly in Visio 2002? Thanks.

Andrew
 
J

John Marshall, MVP

Try putting

ActiveDocument.Version = visVersion100

before the Save as


John... Visio MVP

Need stencils or ideas? http://www.mvps.org/visio/3rdparty.htm
Need VBA examples? http://www.mvps.org/visio/VBA.htm
Common Visio Questions http://www.mvps.org/visio/common_questions.htm
AndrewLLL said:
Does anybody know a decent way of savving Visio 2003 documents to Visio
2002 format in the Visio ActiveX control? In Microsoft website, it showed
these lines:
"You cannot use the SaveAsEx method to save Visio 2003 documents to Visio
2002 format in the Visio ActiveX control. To save a drawing loaded in the
Visio drawing control to Visio 2002 format, launch an invisible instance of
Visio and call the SaveAsEx method in your Visio application instance, as
demonstrated in this Visual Basic 6.0 code that saves a Visio 2003 drawing
into the Visio 2003 file format:
Application.Documents(1).SaveAsEx("C:\Documents and Settings" & _
"\myusername\My Documents\Visio2002 file.vsd", visSaveAsWS + _
visSaveAsListInMRU)"

I am confused by this paragraph. Does anybody understand?

What I am thinking is to save a Visio 2003 document into a XML drawing
file. In this way, can I load the file correctly in Visio 2002? Thanks.
 
A

andreLLL

Hi Joh

I did add this line before I save. It did not work, the file I saved is still in Visio 2003 format

Andrew

----- John Marshall, MVP wrote: ----

Try puttin

ActiveDocument.Version = visVersion10

before the Save a


John... Visio MV

Need stencils or ideas? http://www.mvps.org/visio/3rdparty.ht
Need VBA examples? http://www.mvps.org/visio/VBA.ht
Common Visio Questions http://www.mvps.org/visio/common_questions.ht
AndrewLLL said:
Does anybody know a decent way of savving Visio 2003 documents to Visi
2002 format in the Visio ActiveX control? In Microsoft website, it showe
these lines2002 format in the Visio ActiveX control. To save a drawing loaded in th
Visio drawing control to Visio 2002 format, launch an invisible instance o
Visio and call the SaveAsEx method in your Visio application instance, a
demonstrated in this Visual Basic 6.0 code that saves a Visio 2003 drawin
into the Visio 2003 file format
 
M

Mark Nelson [MS]

Visio 2003 cannot save to an XML file format that can be read by Visio 2002.
You will need to have Visio 2003 save the file as Visio 2002 binary. Then
you can open the file in Visio 2002 and resave it as Visio 2002 VDX if you
like.

The other statement about the control below means that you will need to
perform the save as Visio 2002 using the full Visio application, not the
ActiveX control. Launch an instance of Visio, load your 2003 file, set the
Version property to Visio 2002 and do a SaveAs on the file.
 

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