I develop a tool which works with process diagrams. I need to write an export feature for the tool, that will save current process in Visio VDX format.
I found that Visio saves shapes coordinates in a kind of format which is not easy to understand. For example: PinX 1.476377952755906; PinY 9.448818897637793
My tool operates with shapes and connectors on a discrete net, where coordinates starts from 0,0 and can be only integer, equal or more than zero.
So the question is, how to represent Visio coordinates in VDX file in more understandable format, like millimeters for example.
Dan.
By default, those coordinates in the VDX are inches. Visio internally uses inches for units.
You can specify the units explicitly. For example to set the width of a shape to 100 millimeters:
To test this out I created a VDX file and used millimeters for both height and width formulas and can confirm that Visio 2007 will correctly understand how to read and use these units.
You may notice that the VDX generated by Visio includes the result but not the formula. For example with the PinY cell you will see …
Visio will not accept units in the values for results. This means you can’t put “100mm” inside the tag. The solution is to remove the result value and use the F attribute for the formula. Below is an example.