Hi
i have some boolean fields that are being displayed as checkboxes in my grid - how can i get these to update the database when the user changes the values?
IsEditable is set to false
many thanks
jon
Use one of the following events: UpdateCell, UpdateCellBatch, UpdateRow, or UpdateRowBatch
When you change the checked state of your cell, you're changing the underlying value of the cell to either true (checked) or false (unchecked).
This assumes, of course, that you're using the grid's built-in functionality to display a boolean data type as a checkbox. If you're instead using a tempalted column and putting a checkbox in the cell template, then it depends greatly on how you've set up your cell template - and isn't an approach I suggest unless you need to put other controls in the same cell.
hi,
thanks for the reply vince - i've had a look into this and can't work out what is happening. My grid is in a WARP panel. i've added the updatecellbatch event with some sample code in it and added a breakpoint but this never seems to run.
I am getting the ajax update symbol showing though when the even handler is present in code. But it simply refreshes the grid but does not update the value.
Any ideas where i should look next?
I suggest that you first remove the WARP from the equation. This will make it easier to determine what's causing your updates to not occur.
Once you get your grid's updates to work using postbacks, it should be trivial to put the grid back inside a WARP.
I can't give any more specific advice without knowing more about your setup. If you need more direct assistance, I suggest that you update your sample so that Developer Support will be able to run and debug it, then submit a support request with that sample attached.