It seems that is AllowAddNew is enabled (bottom, bottom fixed, whatever) and AllowUpdate is DefaultableBoolean.False, that you cannot enter any data in the template add row.
That seems flawed to me. If I indicate I want to allow adding rows, obviously I need to be able to update the cell data for that template add row. However I want AllowUpdate to be false so users cannot edit existing rows.
It appears I am stuck with some kind of hack like looping through all existing rows and setting CellActivation to NoEdit, or leaving AllowUpdate False and trying to turn on just for the add row. Or hooking into a cell activate type event.
Is this intended behavior? Can it be changed? Best way to workaround?
We are using v 9.1.20091.2012
Hi,
I tend to agree with you. This doesn't make a lot of sense to me. I'm not sure why it was designed this way. But it's probably not something that we can change at this point, since it would break existing applications.
Anyway, there's another discussion about the same topic here: Allow add new row and disallow update row - Infragistics Community and I posted some code demonstrating how to achieve this pretty easily.
I ended up toggling AllowUpdate in BeforeCellActivate based on e.Cell.Row.IsTemplateAddRow || e.Cell.Row.IsUnmodifiedTemplateAddRow.
The link you provided appears to be malformed. Changed to the below which that solution would probably work too.
http://community.infragistics.com/forums/t/33831.aspx
hudgeo said:The link you provided appears to be malformed.
Oops, sorry about that. I have corrected the link and verified that it works now.