delphi - How to determine if a program needs elevated rights? -


this question has answer here:

imagine following scenario:

i have exe-file "doineedadmin.exe" somewhere , want check if program require admin-rights start it.

it okay trying start , determine failure return value.

since windows can adding admin-icon exe if needs elevated rights, hope it's possible programmatically too.

in short, there no sure way.

windows start program elevated if specified in manifest. start elevated if program name contains setup, install, update, patch (maybe more) (unless disabled local policy or manifest file).

other that, application can request elevation code. there's no way can detect in external program.


Comments

Popular posts from this blog

Command prompt result in label. Python 2.7 -

javascript - How do I use URL parameters to change link href on page? -

amazon web services - AWS Route53 Trying To Get Site To Resolve To www -