I have a Page which takes input from the user and then process his request on a button click. On this button click event, I need to validate the input entered by him and on certain condition show confirmation dialog box. If he clicks Yes, then I need to perform further action else return.
I have tried using
Page.ClientScript.RegisterStartupScript(this.GetType(), Constants.OpenConfirm, "confirm('Data Already Exists, do you Wish to Overwrite the existing record?')", true);
But irrespective of whether I click Yes or No it is performing the further action.
Have have tried using JavaScript method calling from server side, but that is also not working out.