Jump to content

Recommended Posts

Posted (edited)

Hi all,

I'm new here, trying to use autoit to convert many .vdx (visio xml file) to html.

found how to do it in aspx but I don't have asp server and I only want it be on my computer.

aspx code:

// Call Visio to save the XML file to a web page.

VisioDotNet.Application app = new VisioDotNet.ApplicationClass();

app.Documents.Open(VisioFileNm);

app.Addons.get_ItemU("SaveAsWeb").Run(

"/quiet=True /openbrowser=False /target=" +

Request.PhysicalApplicationPath + "VisioDiagram");

app.Quit();

============================================================

can anyone give me a hint how should I do it using autoit? please.

Edited by Justin185
Posted

In the (almost) words of the Thomson Twins, you've got COM, COM, COM on your side.

Global $oVisio = ObjCreate("Visio.Application")
$oVisio.Visible = True
Global $oVSD = $oVisio.Documents.Open("[path to vsd]")
$oSAW = $oVisio.Addons.ItemU("SaveAsWeb")
$oSAW.Run("/quiet=True /openbrowser=False /target=""[path to html]""")
$oVisio.Quit

I hope it isn't necessary but I'm going to say it anyway. Please replace [path to vsd] and [path to html] with some proper values.

WBD

Posted

In the (almost) words of the Thomson Twins, you've got COM, COM, COM on your side.

Global $oVisio = ObjCreate("Visio.Application")
$oVisio.Visible = True
Global $oVSD = $oVisio.Documents.Open("[path to vsd]")
$oSAW = $oVisio.Addons.ItemU("SaveAsWeb")
$oSAW.Run("/quiet=True /openbrowser=False /target=""[path to html]""")
$oVisio.Quit

I hope it isn't necessary but I'm going to say it anyway. Please replace [path to vsd] and [path to html] with some proper values.

WBD

AWESOME!!! you are excellent, it works !!

Thank you so much!

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...