AJAX and RegisterStartupScript

  • Thread starter Thread starter Suling
  • Start date Start date
S

Suling

Hi, I use ClientScriptManager.RegisterStartupScript to create a PopupScript
to display a message dynamically. It works outside of the UpdatePanel. How to
make it working within a UpdatePanel?

Thanks.
Suling
 
Dim Upnl_Main as new UpdatePanel
ScriptManager.RegisterStartupScript(Upnl_Main, Upnl_Main.GetType(),
"MyTestScript", "alert('Hello World!");", True)

Hope that helps!

William
 
Hi William,

I am using C#. I try using UpdatePanel1.GetType() but still not working.
UpdatePanel1 id my UpdatePanel ID.

Judy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top