I have several .aspx pages that use the same javascript functions.These functions include code <%= variable%>.
I want to pass these functions to a .js file but they are not displayed correctly with Visual Studio and also the functions are not executed.
Member
6 Points
39 Posts
Javascript File with Code <%= variable%>
Feb 19, 2020 06:11 AM|zequion|LINK
I have several .aspx pages that use the same javascript functions. These functions include code <%= variable%>. I want to pass these functions to a .js file but they are not displayed correctly with Visual Studio and also the functions are not executed.
All-Star
53001 Points
23594 Posts
Re: Javascript File with Code <%= variable%>
Feb 19, 2020 12:16 PM|mgebhard|LINK
JavaScript files are text files, not part of the ASPX page, and not processed by the framework.
Use standard programming techniques . The simplest is passing the id to the function.
In the aspx page.