AJAX and RegisterStartupScript

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
 
W

William Niver

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

Hope that helps!

William
 
S

Suling

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

Members online

Forum statistics

Threads
473,733
Messages
2,569,439
Members
44,829
Latest member
PIXThurman

Latest Threads

Top