ASP.NET VB PostBack within an Update Panel
I’m trying to have a JS function load on this error (closes Loading overlay & pop-up w/ error should come up). When I try to display the label it works without a problem (of course it’s covered by the overlay).
Me.lblerrormsg.Visible = True
I’ve tried 3 different approaches I’ve found for Registering a Script:
Dim errorScript = "<script>alert('WTF');</script>" '<-- not even this works
Page.ClientScript.RegisterClientScriptBlock(Page.GetType(), "errorDemoManual",
errorScript, True)
'Tried this one with the Panel & Page itself...
ScriptManager.RegisterStartupScript(pnlPatientInfo, pnlPatientInfo.GetType(),
"ErrorDemo", errorScript, True)
ScriptManager.RegisterStartupScript(Page, Page.GetType(), "errorScript",
errorScript, True)
None have worked… Is there something I’m missing here??
The problem was I needed to be using RadScriptManager – part of Telerik UpdatePanels to get it working.