Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
25
cancel postback (confirm delete)
posted

Hi,

I have a grid using a button column for deleting.

I am binding the server side event OnClickCellButton which performs the delete to the model on the server side

I am binding the client side event ClickCellButtonHandler to this:

<ClientSideEvents CellChangeHandler="DeleteClicked" />

function DeleteClicked(gn,cid)

{

if(!confirm("Are you sure you want to delete?"))

igtbl_cancelPostBack(gn);

return false;

}

 

When I click the delete button, and cancel the modal action (or approve it) - the server side event still triggers and I end up with a post back. How do I prevent this post back from occuring?

 P.S. - grid version: 8.1.20081.1000

Thanks in advance!