title: alternative to admin rights - fopen doesn't create C:\temp.txt in windows
body: <p>In my current project I like to use <code>fopen</code> or <code>fopen_s</code> to create a file via "w" option.</p>
  
  <p>Using a QT GUI the user may choose any file name which is basically the return string of a file dialog - similar to what is known to windows dialogs.</p>
  
  <pre><code>QFileDialog::getSaveFileName(this,"Save as...","","all files (*.*)");
  </code></pre>
  
  <p>However, depending on the file name it gets created or not.</p>
  
  <p>So for instance I can write files in my build directory 'C:/SVN/builds/GUI/temp.txt'
  <br>And I can create files on the windows desktop 'C:/Users/XXX/Desktop/temp.txt'
  <br>I can even create files in other build dirs 'C:/SVN/builds/foo/bin/Release/temp.txt'
  <br>But <code>fopen</code> doesn't let me create 'C:/temp.txt' and returns "access denied" (<code>errorno 13</code>)</p>
  
  <p>my issue can be solved like described here: <a href="https://stackoverflow.com/a/4735652/2220850">https://stackoverflow.com/a/4735652/2220850</a>
  <br>but this effectively requires the user to have admin rights for my silly little tool to run properly.</p>
  
  <p>so isn't there another way to get permissions to write the file the user selected from within the GUI?
  <br>Or is there at least for the user and me a way to know where on the disks our tool may or may not create files?</p>
  
  <p>cheers</p>