C
Chris
Hi,
This is a very basic problem, but i am not able to solve it.
msgStr = "<script language =javascript>alert('An exception abc
occured')</script>"
Page.RegisterStartupScript("exception", msgStr)
But if I have want a string like the one shown below, how can I achieve
this ? (Note the single quotes in 'abc')
msgStr = "<script language =javascript>alert('An exception 'abc'
occured')</script>"
Basically, I have a module which creates a string like the msgStr. And
I am passing a string. In this case, I will be passing "An exception
'abc' occured".
But finally, the string becomes as shown in the above line, and gives
some javascript error saying ')' expected.
I tried using 2 single quotes too, but its not working.
TIA..
This is a very basic problem, but i am not able to solve it.
msgStr = "<script language =javascript>alert('An exception abc
occured')</script>"
Page.RegisterStartupScript("exception", msgStr)
But if I have want a string like the one shown below, how can I achieve
this ? (Note the single quotes in 'abc')
msgStr = "<script language =javascript>alert('An exception 'abc'
occured')</script>"
Basically, I have a module which creates a string like the msgStr. And
I am passing a string. In this case, I will be passing "An exception
'abc' occured".
But finally, the string becomes as shown in the above line, and gives
some javascript error saying ')' expected.
I tried using 2 single quotes too, but its not working.
TIA..