how to write javascript inside c#(URGENT)

my javascript doesnt work inside c# using asp.net anyone have a verygood example using javascript inside a c# class its very urgent
thanx alot
loopholesAsked:
Who is Participating?
 
pippothegreatConnect With a Mentor Commented:
im also doing this
heres the code i know how it feels to be in a hurry so ill give you something easy and working.

String strJava = "<script language=JavaScript> ";
        strJava += "do your coding here (everything that was in double quotes are now in single)"      
    strJava += "</";        <-----make sure that its in two seperate lines
    strJava += "script>";  <-----""

        if(!this.IsStartupScriptRegistered("Startup"))
      this.RegisterStartupScript("Startup", strJava);
0
 
loopholesAuthor Commented:
thanks alot pippothegreat i need this badly
0
 
trubes1244Commented:
Is it possible to put this code in a class file?
0
All Courses

From novice to tech pro — start learning today.