Jump to content

Launching .exe files in silent mode help


Recommended Posts

Hello,

I am fairly new to AutoIT and I have been trying to create a script for silent installs on a machine.

There are two separate files I am trying to install one after another.

Is there any reason why I am using the commands

RunWait("C:\ACMS\cache\Juniper_EVPN_Client_17087\Juniper_EVPN_Client_17087\JuniperSetupServiceInstaller.exe /S")

RunWait("C:\ACMS\cache\Juniper_EVPN_Client_17087\Juniper_EVPN_Client_17087\NCInst64.exe /S")

I am not able to run the other command, no errors or anything.

I am able to run that same command through the command prompt.

If I put in

RunWait("C:\ACMS\cache\Juniper_EVPN_Client_17087\Juniper_EVPN_Client_17087\JuniperSetupServiceInstaller.exe /S")

RunWait("C:\ACMS\cache\Juniper_EVPN_Client_17087\Juniper_EVPN_Client_17087\JuniperSetupServiceInstaller.exe /S")

I can install the same service twice but not a different one.

One reason I know it's not installing is because the NCInst64.exe is not prompting me for an admin password like it should.

Thank you for your assistance.

ET

Link to comment
Share on other sites

My UDFs are generally for me. If they aren't updated for a while, it means I'm not using them myself. As soon as I start using them again, they'll get updated.

My Projects

WhyNotWin11
Cisco FinesseGithubIRC UDFWindowEx UDF

 

Link to comment
Share on other sites

I apologize, I feel as though I did not word my question correctly.

I am installing an application that has two install parts to it, first part is the JuniperSetupServiceInstaller.exe and the second part is NCInst64.exe

When I use the RunWait command on JuniperSetupServiceInstaller.exe /S, it works perfectly fine, even without the @SW_Hide flag.

In my code, I have RunWait(~~JuniperSetupServiceInstaller.exe /S") and follow by this line, I have RunWait(~~NCInst64.exe /S")

Is there for any reason why the NCInst64.exe /S isn't even launching when I run this code?

If for some reason I try to run JuniperSetupServiceInstaller.exe twice, it will go through but not NCInst64.exe..

Also, where is the correct place to place the @SW_Hide?

Would it be

RunWait("C:ACMScacheJuniper_EVPN_Client_17087Juniper_EVPN_Client_17087JuniperSetupServiceInstaller.exe /S", "", "", @SW_Hide)

or

RunWait("C:ACMScacheJuniper_EVPN_Client_17087Juniper_EVPN_Client_17087JuniperSetupServiceInstaller.exe /S", @SW_Hide)

Thank you

-ET

Link to comment
Share on other sites

  • Moderators

Hi, EricTan. I would launch the executable manually, then look in your system's temp directory (I always set all users to C:Temp for ease of use). From my experience installing Juniper clients, the executable is simply a wrapper that throws the MSI file into the temp directory, and then hands the process over to the msiexec service. If you grab the MSI, you should be able to install this silently without any problems ("msiexec /i "MSI name" /qn)

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

JLogan,

I am not seeing any msi packages/files in the folder C:UsersxxxxAppDataLocalTemp when installing either of the .exe files.

When I double click the .exe, there is a black status box that displays information such as what is being installed, deleted, updated etc.

Thank you

Link to comment
Share on other sites

Have you tried to manually run the "NCInst64.exe" with the silent switch?

Or do you have any type of response/error checking in your script to get a return value for running the NCInst64.exe?

Just stating since not all packages are created the same and some do not accept the same command line switches.

If you try to fail and succeed which have you done?AutoIt Forum Search

Link to comment
Share on other sites

  • Moderators

That's strange, erictan. I attached a screenshot of what I get when installing...

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

From the command prompt, I am able to run both files silently using the /S switch so I know it is a valid command.

Both files are confirmed to be in the directory path..

Before the RunWait() command, I was using ShellExecute which can definitely launch both files, but neither /S switch or the @SW_Hide flag worked for me..

Link to comment
Share on other sites

  • Moderators

To answer your question about the placement of @SW_HIDE, I would try:

RunWait('"C:ACMScacheJuniper_EVPN_Client_17087Juniper_EVPN_Client_17087JuniperSetupServiceInstaller.exe" /s', "", @SW_Hide)

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

JLogan,

That worked like a charm, I just had to change to switch to /S instead of /s.

Now I am working on launching the second .exe file.. Is there something in AutoIT that prevents me from using RunWait two times in a row?

I tried using ShellExecute which seems to launch the NCInst64.exe file but it's not letting me do it silently.

Any ideas?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...