Format.IsModified Property |
Returns whether or not a BarTender has been modified since the last save operation. Read-only.
Format.IsModified
Version |
BarTender 9.4 SR1 or higher |
Edition |
Automation, Enterprise Automation |
The Format.IsModified property returns true if the active document has been modified since the last save operation; otherwise, returns false. Changes to the document include serialization, default prompt updates, and other document modifications.
'Declare a BarTender application variable
Dim btApp As BarTender.Application
'Declare a BarTender document variable
Dim btFormat As BarTender.Format
'Create a new instance of BarTender
btApp = New BarTender.Application
'Set the BarTender application visible
btApp.Visible = True
'Open a BarTender document
btFormat = btApp.Formats.Open("c:\Format1.btw", False, "")
'Print the document
btFormat.PrintOut(False, False)
'Display whether or not the document is modified
If btFormat.IsModified = True Then
MessageBox.Show("BarTender document has been modified")
Else
MessageBox.Show("BarTender document has already been saved")
End If
'End the BarTender process
btApp.Quit(BarTender.BtSaveOptions.btDoNotSaveChanges)
// Declare a BarTender application variable
BarTender.Application btApp;
// Declare a BarTender document variable
BarTender.Format btFormat;
// Create a new instance of BarTender
btApp = new BarTender.Application();
// Set the BarTender application visible
btApp.Visible = true;
// Open a BarTender document
btFormat = btApp.Formats.Open("c:\\Format1.btw", false, "");
// Print the document
btFormat.PrintOut(false, false);
// Display whether or not the document is modified
if (btFormat.IsModified)
{
MessageBox.Show("BarTender document has been modified");
}
else
{
MessageBox.Show("BarTender document has already been saved");
}
// End the BarTender process
btApp.Quit(BarTender.BtSaveOptions.btDoNotSaveChanges);
Related Topics