I have a visual studio 2010 project. It runs from my notebook fine but from my desktop it won’t run. The error is Microsoft JScript runtime error: ‘$’ is undefined. Here is the code
function fadeDiv() {
$(function () {
$('#ctl00_ContentPlaceHolder1_lblStatus').fadeIn('slow').delay(5000).fadeOut('slow');
});};
this machine had visual studio on it, but i had to remove it and reinstall it again because the silverlight SDK had issue. It has been working fine now for a couple of weeks until this code was inserted into our asp.net code using .net 4.0. I’ve run sfc /scannow and it reported no errors. I’ve also rebooted. The Jscript file exists amongst other places in c:\windows\system32. This is a windows 7 machine 64 bit. The machine is fully patched. the jscript file that is on my machine in c:\windows\system32 is version 5.8.7601.16982 and 799 KB.anyway.. sure hope someone can help me outthanksshannon
The $ variable is used in a couple libraries – most popularly JQuery. It is not Vanilla Javascript. Try including the JQuery script at the top of your code: