I work in asp.net webforms and I create a UserControl which depends on a small amount of javascript that resides in an external file.
I want to be able to reference javascript inside the UserControl to make sure it loads on the page, but the problem is that UserControl can appear several times on the page, so I only want the script to load with the first instance of UserControl.
Is there an easy way to do this in ASP.NET Web formats?
lomaxx
source share