Export XML file for each diagram

Hi,

I am trying to export a project to XML with one XML file for each diagram via command prompt. The ExportXML script exports the given diagrams to one single XML, so i tried to generate a batch file which calls the script for every diagram. This works so far, but it seems to export the diagrams with the option “export sub-diagram when export parents” enabled and because of this it is really slow, and there is no parameter in the ExportXML script to turn it off…

Is there any possibility to get a single XML for each diagram or to turn off the sub-diagram export in cmd?

Best regards,
Tom

Hi Tom,

Your sub-diagrams are included in the XML does not related to “Export sub-diagram when export parents” option.
For Example:


When you select D1 to export, the D1a must be included in the exported XML.
We now have no option to exclude that.

Sorry about that, at this moment, we have no plan to support excluding sub-diagrams.
I don’t prefer supporting it, because, the sub-diagram (or children) of a element, should be the content of the element (a part of the element), so, should be included.


On another hand, seems the real problem you faced is Slow on exporting.
I just tested on a simple project. It used 6 sec. on 1 exporting, where,

  • 4 secs is used in startup & open project;
  • 2 secs is used in export XML;

for example, export 10 diagrams used (4 x 10) + (2 x 10) = 60 secs.

This problem can be fixed by supporting a new command line option (such as -DiagramPerFile), that, will start & open project 1 time, and export all diagrams into different xml files.

means, export 10 diagrams will use (4 x 1) + (2 x 10) = 24 secs.

Do you think the new option can help you? If yes, I think we will support it in these few days. (I think…)