You noticed, I hope my latest two posts on SVG - this one and this one – and for my third I’m going to give you a preview of a small tool I’m working on. It will be a part of my Visio Power Tools add in (which is found in my VisioAutomation project on CodePlex).
The new release of the tool is coming soon, and here’s what you’ll be able to do:
Load a nice Visio Diagram …
Select Power Tools > Import / Export > Export Selection as SVG + XHTML
A form will let you pick a filename (.XHTML) to save the drawing. (Yes, I know the form isn’t very nice – that’s why I’m calling this a preview)
Click OK and that XHTML file will be created .
You can then right-click on that file and open in FireFox 3.6 or Google Chrome (and eventually IE9)
And you will see them render your diagram …
This is what FireFox 3.6 shows
This is what Chrome shows …
HOW IT WORKS
This is pretty simple. My code exports the Selection as SVG (you can see the temporary svg file in one of the screenshots above) and then wraps that SVG in some XHTML tags. The code is very, very simple.
WHERE TO GET THE POWER TOOLS
I plan on publishing version 2.5 of my VisioAutomation library in a week or two. You can get the latest version of my Visio Power Tools then.
If you are super-curious you can visit the VisioAutomation project on CodePlex and then download the latest source code and build it with Visio Studio 2008.