Home/ Reference/ Import / Export

app.OpenDocument(path)

Opens an existing file. For batch edits, walk them with app.Documents.Item(i).

Signature

app.OpenDocument(path)

Notes

Opens an existing file. For batch edits, walk them with app.Documents.Item(i).

Python example (runnable)

Requires pywin32. The example assumes app / doc / page / layer are already connected. See Connection & Init
Python
path = "D:/artwork/template.cdr"

doc = app.OpenDocument(path)         # open it and return the Document
print("Opened: ", doc.FileName)
print("Pages: ", doc.Pages.Count)

# once open you drive it like any new document

About this section: Import / Export

Import / Export — import, export, save and print.

Other entries in this section