I have an application that does a loop which starts some processes programmatically one by one. My app itself runs under a standard user, but I need to run only those processes as admin so I can install them.
To achieve this, I use the 4th response from this thread
My two questions are:
is that code which is pointed in the above response, supposed to ensure that the process automatically runs as admin, or that the user is shown a dialog where he chooses whether to run as admin or not? I am confused by what this code is supposed to do.
Also, in case a dialog is supposed to be given to the user - how can the app be coded, so that the first user option is remembered in my loop for the next processes started with the verb "runas" ? So basically to store somewhere the user option (run as admin or not) for the other processes.
Thank you in advance