New BO Property 'SetDirtyOnEdit'


Author
Message
Tim Dol
Tim Dol
StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)
Group: Forum Members
Posts: 340, Visits: 1.4K
I cannot find any documentation on this new property and have a question on how it's supposed to work with the Maintenance Form Toolstrip. When this property is set to 'True' (Default) and you click on edit button (IsDirty is set to True), New/Edit/Delete and Browse buttons are disabled, Save and Undo buttons are enabled and the save dialog is always displayed regardless if a change is made.

When SetDirtyOnEdit is 'False' and you click on edit, all the buttons on the toolbar are disabled and  'IsDirty' is only set when a value is changed. All the buttons remain disabled even if you change a value. 

Is there something I'm missing or is the intended behaviour? Shouldn't the toolbar buttons remain in their original state until a value is changed?

Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
Is there something I'm missing or is the intended behaviour? Shouldn't the toolbar buttons remain in their original state until a value is changed?

This is the intended behavior.  It is not recommended to use the MaintenanceFormToolstrip in the manner.  Regardless, when you set the SetDirtyOnEdit to False, the EditingStateChange event will not fire the same way, which is the event that triggers the MaintenanceFormToolstrip to update itself.  The reason for this is because the IsDirty state is changing, but the EditingState was never modified.  When using the standard MaintenanceFormToolstrip and standard maintenance forms, it is recommended to leave this property alone if you want the MaintenanceFormToolstrip to manage itself.  Otherwise you can create your own MaintenanceFormToolstrip and manage the buttons yourself based upon your desired behavior and the IsDirty property.

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search