Visio Macro that can Save as the visio sheets into html.

Hi,

Visio Macro that can Save as the visio sheets into html.
This is the continuation of Scott's macro that needs to save all all the rows converted to charts and saved as Html.

Need the file names as NTlogin's and saved as html. All files into 1 folder.

Regards
Sharath
LVL 11
bsharathAsked:
Who is Participating?
 
Scott HelmersConnect With a Mentor Visio Consultant, Trainer, Author, and DeveloperCommented:
Sharath,

The attached file is essentially the same code we created in
   http://www.experts-exchange.com/Microsoft/Applications/Microsoft_Visio/Q_23854187.html
but it now assumes the header row in Excel is row 2 instead of row 1.

In addition, it now creates a web page for each Visio page. I've used the standard save as web page function in Visio so it creates a subfolder to contain all of the various files. After Visio creates the files using its naming structure, the macro renames each file to reflect the NTlogon of the user.

Note also that there are actually two files per user -- one is the html file and one is the jpg image of the Visio page. All html and jpg files are named beginning with "NTlogon = " so you'll find pairs of files like this:
   NTlogon = Sharathk.htm
   NTlogon = Sharathk.jpg

Just drag the html file to a web browser to see the results.

BTW, the default resolution for the jpg images is 800x600. Let me know if you'd like me to save them at a higher resolution.

Scott
Excel-to-Visio-to-html.zip
0
 
marklorenzCommented:
Check this out:

automate exporting a Visio drawing as an HTML document set
http://support.microsoft.com/kb/258489



0
 
Scott HelmersVisio Consultant, Trainer, Author, and DeveloperCommented:
Mark,

Thanks for the suggestion. The KB article you linked to applies to Visio 2000 -- and fortunately, there is much better and easier-to-use support for creating html pages in Visio 2003 and 2007.

You can see the code I used in the file posted above if you're interested. Otherwise, the Visio 2007 SDK has a couple of good examples (in fact, my code is adapted directly from the SDK examples).

Scott
0
Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

 
bsharathAuthor Commented:
Thank U Scott checking now.
One question in the visio can i do any alignment. Is that allowed? Will that changes reflect in the html pages?
0
 
Scott HelmersVisio Consultant, Trainer, Author, and DeveloperCommented:
Any changes you make on the background page called "Template" will appear on all Visio pages.
0
 
marklorenzCommented:
Thanks Scott - I'll check it out
0
 
Scott HelmersVisio Consultant, Trainer, Author, and DeveloperCommented:
One other suggestion -- you might want to save the Visio document as a .vst (Visio template) instead of as a .vsd. That way, each time you open it, it will create a new document into which to insert the pages, leaving the .vst "clean" for the next time.
0
 
bsharathAuthor Commented:
Thank U Scott for this help... :-)))
Works perfect...
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.