Wednesday, February 22, 2006 5:52 PM
by
chad
Where is my WebUIValidationjs?
So I was writing a 1.1 ASP.NET app, and I kept getting this pop-up/alert (from client-side JS) in the browser:
"Unable to find script library '/aspnet_client/system_web/1_1_4322/WebUIValidation.js'. Try placing this file manually, or reinstall by running 'aspnet_regiis -c'."
I googled this message and found all sorts of cures and I tried them all, to no avail.
Add this as one more possible solution. I checked my HTML source and I found this near the top:
<script language='javascript' src='scripts/WorkScheduleControl.js'/>
<script language="javascript" type="text/javascript" src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>
Note the "/>" on the end of my script tag? Yeah, that's the culprit. IE didn't load the second script tag, and thus didn't ever load WebUIValidation.js.
Even though I had the DTD set to xhtml1-strict, IE still doesn't support self-closing tags for the <script> tag apparently.
Changing my <script> declaration to <script lan....></script> fixed the problem!
Hope this helps someone and saves them a few hours of grief.