Tuesday, October 30, 2007

Delete confirmation using javascript

//Html view code

ImageButton ID="imgbtnSave" runat="server" ImageUrl="Images/btnSaveSO.gif" ValidationGroup="WODueDateValidation" OnClientClick="javascript:return SaveConfirmation()" OnClick="imgbtnSave_Click"

//Javascript

function deleteConfirm()
{
if(confirm('Are you sure, you want to delete this item permanently from current Sales Order?'))
{
return true;
}
else
{
return false;

}
}

No comments: