title: Visual Studio 2008 jQuery IntelliSense sporadically fails, restarting VS fixes
body: <p>Right off the bat, this is not your standard "I can't get javascript IntelliSense to work in Visual Studio."  For the record:</p>
  
  <ul>
  <li>I'm using Visual Studio 2008</li>
  <li>I have installed SP 1</li>
  <li>I have installed the hotfix for -vsdoc.js documentation files <a href="http://code.msdn.microsoft.com/KB958502/Release/ProjectReleases.aspx?ReleaseId=1736" rel="nofollow noreferrer">KB958502</a></li>
  </ul>
  
  <p>I am developing a suite of interrelated jQuery plugins to be packaged as resources in a class library.  So within a directory, I have (as an example):</p>
  
  <ul>
  <li>jquery-vsdoc.js</li>
  <li>core.js</li>
  <li>plug1.js</li>
  <li>plug2.js</li>
  </ul>
  
  <p>In core.js, I have the following at the top of the file:</p>
  
  <pre><code>/// &lt;reference path="jquery-vsdoc.js" /&gt;
  </code></pre>
  
  <p>Then in each of the plug#.js, I have:</p>
  
  <pre><code>/// &lt;reference path="jquery-vsdoc.js" /&gt;
  /// &lt;reference path="core.js" /&gt;
  </code></pre>
  
  <p>The IntelliSense works initially, even including the additions from core.js when working in the plugins.  However, sometimes the slightest change, even adding and removing a space from the reference XML tags, or pressing Ctrl-Shift-J, results in the dreaded "Error updating JScript IntelliSense: Client-side script IntelliSense information was not generated due to an error in an external script reference."  Except it was working with that external script reference just a second ago!</p>
  
  <p>For the jquery-vsdoc.js, I am using Comment Version 1.3.2b (that's what it says in the file) from <a href="http://jqueryjs.googlecode.com/files/jquery-1.3.2-vsdoc2.js" rel="nofollow noreferrer">http://jqueryjs.googlecode.com/files/jquery-1.3.2-vsdoc2.js</a>.  I am omitting the version number from the file so that I don't have to change a bunch of references when it's inevitably updated.</p>
  
  <p>So what could be the problem?  Restarting Visual Studio is proving to be a horribly inelegant (and time-consuming) workaround.</p>