How to make a vb.net 2008 application run As Administrator
Posted on 2008-10-12
This is very frustrating! I have an application that needs to have permission to create folders and files on the users PC. So with Vista I need to have admin rights in order for the program to work properly. All I am able to figure out is how to get the setup.exe file to run as admin. What I need is the actual installed application to run as admin so it can create the folders and files as needed. After I install the application, if I go to the shortcut it creates or even the application itself and right-click, it does not give me the option to run ad administrator (its not in the advanced options under properties either). When creating the application I went to the publish properties and set it to as for admin rights, but it only seems to do this when installing the app, not when running the installed app. Does anyone know how I can set this up so that it prompts for admin rights when the user runs the installed app?