Click here to Skip to main content
15,897,968 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
HttpContext.Current.Application("Status_ChatWindow") = uname

in code behind i set this value.. i need to access this value in javascript..how to access this value??????
Posted
Updated 30-Jan-14 0:13am
v2

1 solution

You can't do that directly.

Instead store that in a HiddenField. Access that HiddenField value in JavaScript.
 
Share this answer
 
Comments
rhl4569 30-Jan-14 6:31am    
but it cant store the value in hidden field. because it is shared web method. when i m storing the value in hidden field then it gives error as object reference not set to an instance of object..?
The other way would be calling a Web Method by jQuery and get the value.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900