Thursday, May 22, 2008

ASP.NET popup with return values.

Some people have problem creating a page that returns value to master window.

I found this article by Peter A. Bromberg, Ph.D. which is good to create popups with return values.

http://www.eggheadcafe.com/articles/20060117.asp

You can use the registerstartupscript and registerclientscript for many purposes.


string script = "<script language='javascript'>"
script += "alert('Hello');"
script += "</script>"

RegisterStartupScript("StartUp",script)