Draw.IO Export to XML via Command Line Interface

462 views
Skip to first unread message

Paul Cleverley

unread,
Feb 5, 2021, 7:20:38 AM2/5/21
to diagrams.net Q&A
I have version 13.0.1 of Draw.IO running under Windows 10

I believe the following command should produce an XML export of the test_translate.drawio file. If I export from the UI it works fine. This command however produces a file which is actually a PDF file...

"C:\Program Files\draw.io\draw.io.exe" -x test_translate.drawio -o testme.xml

Is there something I am doing wrong? 

Thanks
Paul

David Benson [diagrams.net]

unread,
Feb 5, 2021, 7:22:14 AM2/5/21
to diagrams.net Q&A
Update to latest and try again.

Paul Cleverley

unread,
Feb 5, 2021, 7:52:50 AM2/5/21
to diagrams.net Q&A
Thanks David - I would but I think our corporate licence is only for this version. I will check!

David Benson [diagrams.net]

unread,
Feb 5, 2021, 7:54:00 AM2/5/21
to diagrams.net Q&A
It's an open source project, https://github.com/jgraph/drawio-desktop/releases, nobody has any restrictions on version usage.

Paul Cleverley

unread,
Feb 5, 2021, 10:00:25 AM2/5/21
to diagrams.net Q&A
Hi David,

Thanks - I've got 14.1.8 now. It's fixed the PDF problem ! and I can export with -u uncompressed to get the XML I need which is great!!

Except - as I want to run it from a batch file the command line interface seems to wait for a keypress (Enter / Return key) at the end of the export before it closes? Should I raise this as a separate issue?

Many thanks for your help!

David Benson [diagrams.net]

unread,
Feb 5, 2021, 10:01:13 AM2/5/21
to diagrams.net Q&A
Yeah, new github issue please.
Reply all
Reply to author
Forward
0 new messages