title: Debugging FiddlerScript
body: <p>Does anyone know how to debug through FiddlerScript?</p>
  
  <p>I tried what seemed like the obvious thing to do:</p>
  
  <ol>
  <li><p>In the Fiddler CustomRules.js, insert this code:</p>
  
  <pre><code>if (Debugger.IsAttached) 
      Debugger.Break();
  </code></pre></li>
  </ol>
  
  <p>(and also at the top of the file: import System.Diagnostics;)</p>
  
  <ol>
  <li><p>Open the CustomRules.js file in Visual Studio 2010, and then in Visual Studio do Attach to Debugger, selecting the Fiddler process as the debugging target.</p></li>
  <li><p>Browse to a website.</p></li>
  </ol>
  
  <p>This half-works: Visual Studio stops when the Debugger.Break() statement is hit, but the problem is, all it shows me is the disassembly window - not very useful! VS doesn't seem give any option to connect the source code in CustomRules.js.   I'm <em>guessing</em> that the problem is probably that it needs a pdb file and there isn't one, but it's not clear to me how to provide one.</p>