Prompt with UAC when user doesn't have access to copy a file

Posted by Will Eddins on Stack Overflow See other posts from Stack Overflow or by Will Eddins
Published on 2010-06-17T19:57:59Z Indexed on 2010/06/17 20:43 UTC
Read the original article Hit count: 143

Filed under:
|
|

In my application, if the user saves a file to a folder they don't have permissions for, File.Copy will fail. An example is saving a document to the C:\ root.

Instead of denying access, I'd like to prompt the user to elevate permissions with a UAC prompt, but only for this save function (not for the entire application). Is there a way to do this?

© Stack Overflow or respective owner

Related posts about c#

Related posts about file-io