Accessing Java Script from Code behind
ASP.NET
2
Posts
2
Posters
0
Views
1
Watching
-
Well you can't really access it as it does not run at the same time. Your code-behind runs server-side and your javascript runs client-side. You could use the RegisterScriptBlocks to add javascript to your HTML, or the Control.Attributes.Add(key, script) function to add javascript event handling to your controls though. If you need to access the result of a javascript function you must take other means, such as putting the result in a hidden text box, and reading it server side. hope this helps, sivilian