View Single Post
  #1 (permalink)  
Old April 9th, 2009, 09:14 AM
abhishekkashyap27 abhishekkashyap27 is offline
Authorized User
 
Join Date: May 2007
Location: Hyderabad, Andhra Pradesh, India.
Posts: 95
Thanks: 5
Thanked 0 Times in 0 Posts
Question Alert for popup blocker in C#

Hi All, i have a very specific problem. I am opening a new window while clicking on print button. I want to give alert - "Please turn off the popup blocker' whenever the popup is blocked. How can i do this in c#. My application is a web application and i have developed it using c#.

code -

Code:
protectedvoid btnPrint_Click(object sender, EventArgs e)
{
Empno = Convert.ToInt16(Session["UserID"]);
ScriptManager.RegisterStartupScript(this, GetType(), "open", "popupWin=window.open('LT_Application_New_Claim_Print.aspx?Mode=" + "PRINT" + "&Empno=" + Empno + "&Balance=" + txtBalance.Text + "&AdvanceClaimed=" + txtAdvPaid.Text + "&ApplnNo=" + hdnApplnNo.Value + "&PageType=" + hdnPageType.Value + "&Location=" + Session["LocCode"].ToString() + "&AppnType=" + hdnAppnType.Value+ "','LTA', 'height=400, width=980,scrollbars=yes, resizable=yes');", true);
}

How can i throw alert through c#

--Abhishek