title: javascript eval() fails with window.external.notify(), works with window.alert()
body: <p>On WP8, if I execute (1):</p>
  
  <pre><code>Microsoft.Phone.WebBrowser wb;
  wb.InvokeScript("eval", "window.external.notify('abc');");
  </code></pre>
  
  <p>It throws a 'target of invocation returned an error', unknown error, hresult 80020101.
  But (2)</p>
  
  <pre><code>wb.InvokeScript("eval", "window.alert('abc');");
  </code></pre>
  
  <p>works fine, and displays the message box.</p>
  
  <p>And (3)</p>
  
  <pre><code>wb.InvokeScript("eval", "( function (){window.external.notify('abc');})();");
  </code></pre>
  
  <p>Also works fine.</p>
  
  <p>My question is, what is it about window.external.notify() that prevents eval from invoking it directly?  It is a function call, like window.alert(), so it should be a valid script.  But if there is something special about the unadorned call in 1), then why does the wrapped call in 3) work?</p>
  
  <p>I understand that eval() is the root of all evil, and I have read other SO posts relating to eval() problems with a function definition.  (Where would we all be without SO?) But this is clearly a different problem.</p>