please help.
I'm trying to run a script from a inside shared function:
Dim strScript As String
strScript = "<script language=JavaScript>"
strScript += "alert(""" & string1 & """);"
strScript += "</script>"
HttpContext.Current.Response.Write("alert(""" & string1 & """)")
If (Not Page.ClientScript.IsStartupScriptRegistered("clientScript")) Then
Page.ClientScript.RegisterClientScriptBlock(MyPage.GetType(), "clientScript", strScript)
End If
I'm getting an error in this line: Page.ClientScript. The message is: "Reference to a non-shared member requires an object reference"