title: Creating file on Windows 7 causes "Access denied" exception
body: <p>I have a Java application were the user can create a text file and save it wherever he wants on his computer using this code :</p>
  
  <pre><code>File txtFile = new File( path );
  Writer writer = new BufferedWriter( new OutputStreamWriter( new FileOutputStream( txtFile ), "UTF-8" ) );  // Error occurs here.
  </code></pre>
  
  <p>But many users using Windows 7 reported that when saving the file to <strong>"C:\"</strong>, they get "<strong>Access is denied</strong>" error. I found that this is because they need administrator permissions to save the file in such path in Win7.</p>
  
  <p>Instead of showing a warning message to the user: " <em>You can't save the file at this path</em> ", can i save the file in this path somehow, like if there is a way to have Administrator permissions in Win7 through Java code, or something like that ?</p>