I am having a bit of a problem. I have the following code:
if (GetSelectedUsers().Count() > 0) {
string script = "alert('not show this message');";
System.Web.UI.ScriptManager.RegisterClientScriptBlock(btnActivateDeactivate, this.GetType(), "Test", script, true);
Response.Redirect("FUserManagement.aspx");
} else {
string script = "alert('This Message works');";
System.Web.UI.ScriptManager.RegisterClientScriptBlock(btnActivateDeactivate, this.GetType(), "Test", script, true);
}
The second message works, but the first does not. I am new to ASP.NET. Can you help to archive this type of functionality? The problem in appears to be in the Response.Redirect method. When I comment it out, everything works normally, but I cant delete Response.Redirect as this is part of my functionality.