Yes...

By Onur Tosyali

.NET, import a variable from .cs to .aspx or .js




Here, psAppPath is a global string variable in the .cs file, as
public string psAppPath;



Similarly, you can reach your .cs variables from javascript, but only after importing them as:




on your .js file (or the javascript extension of your .aspx))

No comments:

Post a Comment