Hack Forums
[.NET] Run with admin rights - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [.NET] Run with admin rights (/showthread.php?tid=4355213)



Run with admin rights - iLogic™ - Jul 23, 2014

Hi everyone! 😉
I need help... Im creating app in vb 2010 that is writing files and creating directories on disk C. But app must run with admin rights for doing that. I need code, that will make app runable with admin rights (app will required admin rights for running).
Thanks for help 😉


* - ThereThatGuy - Jul 23, 2014

Right click on your project and choose properties, Then click View Windows Settings
Look for
Code
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
Change "asInvoker" to one of these

level="asInvoker" (normal)
level="requireAdministrator (require administrator)
level="highestAvailable" (if something is higher then admin use that)


* - iLogic™ - Jul 24, 2014

Thank you for answer 😉 it works