cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
phreeman
Level 2

How can I execute script as an administrator?

Hi,

I have some trouble with executing script with InstallScript project.

I am using InstallShiedl 2020 Professional and I put some script into InstallScript project.

And I need to execute some part of script with an authority of administrator.

Please share any idea regarding my issue.

Thanks.

Labels (1)
0 Kudos
(2) Replies
Azmaeus
Level 6

Hi @phreeman ,

What are you trying to execute as administrator? Is it an executable? If so, you can use LaunchAppAndWait, and specify LAAW_SHELLEXECUTEVERB = "runas" before running LaunchAppAndWait. I haven't tried this, but hopefully this gets you some information to get you started.

varul
Revenera Moderator Revenera Moderator
Revenera Moderator

You can use "LAAW_SHELLEXECUTEVERB=runas" at the beginning of your script, so that your script will run as administrator, Please refer below help link

 

https://docs.revenera.com/installshield26helplib/LangRef/LAAW_SHELLEXECUTEVERB.htm