Detecting unsaved changes
- 
Hi,
Is there a call to c4d to ascertain if there are unsaved changes in the current session. The current session was started from opening a file from disk.
I am using R21 on Windows and using Python.
Cheers
 - 
Hi @nicholas_yue this is indeed something not documented but you can know it by accessing the
c4d.DOCUMENT_USERCHANGEparameter of a document.doc = c4d.documents.GetActiveDocument() isChanged = bool(doc[c4d.DOCUMENT_USERCHANGE])The parameter
c4d.DOCUMENT_USERCHANGEis an integer that can have 3 values:- 0 means there is no change
 - 1 means there is a change in the scene.
 - 2 means there is a change from the undo stack.
 
Cheers,
Maxime. - 
Is BaseDocument.GetChanged() what you want? See Changed Mode.