Hi,
I have used the wizard to convert asp.net 1.x to asp.net 2.0 website.
I have a utiliities.vb class file that contains a public class utiliites.
A shared function called JavaMessagebox uses the registerclientscriptblock.
The problem is that I am getting the clientscript is undeclared with the following code statement:
ClientScript.RegisterClientScriptBlock(pg.GetType(),
"ClientScript", scripting)Normally this code would be in the code-beside? (formally codebehind) file and would see this class because of the
Inherits
System.Web.UI.Page
However I can't add the inherits statmenet to a public class.
Should I just migrate out this code and put it in my webpages? I'd prefer to get it working without pasting it into
the code behind page for the webpage that call this JavaMessageBox function.
Thanks
Haggisns
Haggisns
![]() |
0 |
![]() |
use like
Page.ClientScript.RegisterClientScriptBlock
looks like you are having a varible called Pg that is your Page so u can call like Pg.ClientScript.RegisterClientScriptBlock as well
Raghu
(MCSD.NET, MCAD.NET, MCDBA)
[Don't forget to click on Mark as answer on the post that helped you ]
![]() |
0 |
![]() |
duh!.. thanks rmaiya :), I totally space out on that one, even my limited OO knowledge should have figured that one out.
thanks, it works.
Haggisns
![]() |
0 |
![]() |