views:

129

answers:

2

I have a special feature in my AP, this feature need to get administrator right in Vista. Is there any MS API to pop up the UAC dialog when I click the button? Because I don’t want the end-user to see UAC dialog during startup, the feature is really special, not every user will do that. Thanks in advance.

+1  A: 

Similar question here.

Peter
A: 

Nope, MS has spent lots of time to make programmatic access to that button impossible! If you could do such a thing, UAC would be absolutely useless. You might encapsulate the functionality as a something (e.g. a Windows service) running with admin privileges. on which you'll call a method from the non-elevated process.

Mehrdad Afshari
I think he wants to elevate his process in the middle of it, as discussed here:http://stackoverflow.com/questions/78696/vista-uac-access-elevation-and-net
Martin Plante
But this doesn't make the process click that "continue" button. And after elevation, the process will be elevated forever which is not what the question asks.
Mehrdad Afshari