Closes the document.

syntaxSyntax:
DlxDocument.Close()

Return Value

If the document cannot be closed or is already closed, this function returns false. If the document is open, and is closed correctly, it returns true.

Remarks

If the document has been modified, a dialog box appears asking you to confirm the operation and proposing to save the data in the Job. To force closing the document without displaying the confirmation window, first call the Store function to save the changes or call the SetModified function specifying false to discard the changes.

Example

  Copy codeCopy code
var doc = DlxApp.GetJob().FindDocument("Example Sch", DlxApp.DOCTYPE_SCHEMATIC);
if (doc.IsOpen())
{
  doc.Close();
}

See also