question

TllyHwk-8380 avatar image
0 Votes"
TllyHwk-8380 asked TllyHwk-8380 answered

Running arguements for exe applications in powershell

Hello. I've been trying various arguments to install an .exe application silently and nothing seems to work. Would you have any suggestions on how I'd solve this?
I'm trying to have the .exe install silently and also fill in all the answers that would normally pop up through the user interface by .iss file. However, I've never gotten the .iss to fill in the questions nor to get the application to run silently. I don't mind letting you know the application is called Respondus4Campus.exe. I'm currently trying variations of the below line. This is also my first time using .iss file. Thank you for any help or direction.

start-process -FilePath "c:\temp\Respondus4Campus.exe" -verb RunAs /S /f1"C:\temp\setup.iss" /f2"C:\temp\my-log-file.iss"

windows-server-powershell
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

MotoX80 avatar image
0 Votes"
MotoX80 answered

In some respects, a Powershell prompt is no different from a command prompt. If you need UAC elevation to generate an ISS file, launch Powershell with "Run as administrator".

And you really don't need Start-Process, just run the program like you would in a command prompt.

 c:\temp\Respondus4Campus.exe /S /f1"C:\temp\setup.iss" /f2"C:\temp\my-log-file.iss"

If it doesn't generate the iss file then you will need to contact the software vendor to ask for help. That's not something that we could help you with.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

LimitlessTechnology-2700 avatar image
0 Votes"
LimitlessTechnology-2700 answered

Hi TllyHwk-8380,

If your application uses a standard installshield exe, there are two ways in which you can create an InstallShield Silent response file: you can run the installation and have InstallShield record and create the response file for you, or you can write the response file directly.

Recording a Response File

You have the option of letting InstallShield create the response file for you. Simply run your installation with the Setup.exe -r command-line parameter. InstallShield will record all your installation choices in Setup.iss and place the file in the Windows folder.

All InstallShield built-in and Sd dialog functions are designed to write values into the Setup.iss file when InstallShield runs in record mode (Setup -r). If you are creating custom dialogs, you will need to call SdMakeName and SilentWriteData to add sections and dialog data to the response file when the installation runs in record mode. Refer to the Sd dialogs' source code in the <InstallShield location>\Include folder for examples of using these functions to write to Setup.iss. Read the following section for more information about what data to add to Setup.iss when calling SdMakeName and SilentWriteData.

Manually Creating a Response File

You can also create the response file completely by hand. As mentioned, the Setup.iss file is similar to an .ini file. The sections of an InstallShield response file must be in the following order:

  1.  Silent Header Section
    
  2.  Application Header Section
    
  3.  Dialog Sequence Section
    
  4.  Dialog Data Sections (one per dialog)
    

Section names are contained in square brackets, as in [InstallShield Silent].

Data entries follow their section names and consist of <name=value> pairs, as in the following example:

Dlg0={23EAFFCA-361D-11D3-8B0F-00105A9846E9}-Welcome-0




--If the reply is helpful, please Upvote and Accept as answer--

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

TllyHwk-8380 avatar image
0 Votes"
TllyHwk-8380 answered

The above didn't work but thank you all for your help as it got me close enough to get one line that worked.

start-process -filepath "C:\temp\Respondus4Campus.exe" -wait -verb RunAs -ArgumentList '/s /f1"C:\temp\setup.iss"'

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.