StrataFrame Forum

Navigating a Grid

http://forum.strataframe.net/Topic21745.aspx

By Bill Cunnien - 1/30/2009

I am stumped. If I select a row on a grid, click edit, then navigate (click on another row or use the navigate buttons) away without changing any values, the BO considers the row dirty (IsDirty=true). Why is that? This is having some profound effects on my data. The row is being updated when nothing is really being updated.



Thanks!

Bill
By Ivan George Borges - 1/31/2009

Hi Bill.

You can try working with the SetDirtyOnEdit property. There are some posts about it here on the forum, here is one of them:

http://forum.strataframe.net/FindPost3384.aspx

Abraços.

By Trent L. Taylor - 2/2/2009

It looks like Ivan is probably on the right trail here.  By default, when you call Edit on a BO, the IsDirty state will become True.  You can prevent this a couple of ways.  Set the property like Ivan mentioned, or don't use editing states at all, which is the approach that we generally use.  Instead of requiring the user to click 'Edit', we will always leave our fields enabled (like the StrataFlix sample) and then when a change is made, we will handle the IsDirtyChanged event and take whatever actions necessary to preset Save, etc.