how to show the alertbox first and then log out
if (machineID.Count != 0)
{
checkMachineGrpState(machineID);
else
{
Response.Write("<script>alert('You are being logged out')</script>");
GoSignOut();
}
}
private void GoSignout()
{
FormsAuthentication.SignOut();
Session.Abandon();
Response.Redirect("~/Default.aspx");
}
here if i dont call the GosignOut function i can see the alert box but the moment i put call the signout it does not show me the alertbox and simply signs out
So i was thinking if there is a way i can see the alertbox first and then when i press OK it should call signout function in my code behind... thanks