title: In a local WPF Web Browser Application how do I write to a file? Sandbox doesn't allow?
body: <p>So I have a local WPF web browser application and I need it to write to a text file. However I always get the an exception of type System.Reflection.TargetInvocationException. I don't get any more information but I'm pretty sure it is because it is being run from a web browser (security etc.).</p>
  
  <p>The code I am using works in a regular windows form application etc. it is the usual:</p>
  
  <pre><code>        StreamWriter sw;
          sw = File.CreateText("c:\\myTextFile.txt");
          sw.WriteLine("First line");
          sw.Close();
  </code></pre>
  
  <p>So, is there a workaround for this?</p>
  
  <p>Many thanks,
  Thomas</p>