2
votes

I have an Inno Setup generated setup that has two separate EXE's (eg: A.exe and B.exe) bundled on to it.

A.exe or B.exe is identified via command line argument and executed. Only one application will be installed at a time.

A.exe -> can only be run by Admin.

B.exe -> any user can run

If, a non-admin user tries to install A.exe, which requires admin privileges, I want to automatically detect that and run B.exe which is designed for Non-admin users.

So far in the code I've used PrivilegesRequired=admin

1
I'm not sure I understand what you ask for, but I've tried to answer.Martin Prikryl

1 Answers

2
votes

Use IsAdmin function (or IsAdminInstallMode or IsAdminLoggedOn [in older versions]) to detect, if the installer is running with elevated privileges or not.