I have few questions regarding usage of the client side OnColumnMooving..() events.
1.
I would like to cancel column moving event if certain condition occurred (using ReorderColumnsOnClient="true")
for example here is my js method that cancels the event for first 2 columns in the grid.
function ColumnMoving(sender, eventArgs)
{
if(eventArgs.get_gridColumn().get_element().cellIndex < 2)
{
eventArgs.set_cancel(true);
}
}
But what i find is when an event is canceled once, it never fires again for any of the other column.
2. Is it possible to use this event when ReorderColumnsOnClient is set to "false"?
3. How can I find out the destination index of the column that is being reordered(meaning where is it about to be moved)?
Thank you
Polina
1.
I would like to cancel column moving event if certain condition occurred (using ReorderColumnsOnClient="true")
for example here is my js method that cancels the event for first 2 columns in the grid.
function ColumnMoving(sender, eventArgs)
{
if(eventArgs.get_gridColumn().get_element().cellIndex < 2)
{
eventArgs.set_cancel(true);
}
}
But what i find is when an event is canceled once, it never fires again for any of the other column.
2. Is it possible to use this event when ReorderColumnsOnClient is set to "false"?
3. How can I find out the destination index of the column that is being reordered(meaning where is it about to be moved)?
Thank you
Polina