How to add an argument to the command-line of an application?
Currently I have a scripted installation running, installing the complete computer and joining the computer to the domain. The step to join to domain, I now have it as a PowerShell script which is called by a batch script, because running PowerShell directly doesn't work.
Because I don't want to add username and password to any script, I want to add the username and password as an argument to my script in the following way:
commandline: install.bat domain\username password
powershell.exe -executionpolicy bypass -file "%~dp0install.ps1" %1 %2
When I try to run this via a scripted install, I receive the error that it cannot find the file. When I then look into the XML, I see the following:
<CommandLine><![CDATA[install.bat domain\username password]]></CommandLine>
With other words, the parameters / arguments are in the wrong place.... In my application, I don't have any option to add parameters, I only have the commandline box to fill, so from the console I just cannot set this correctly?!
I know I can change the xml manually and add the parameters, but I don't want to do this manual action each time I update the Scripted Install....
Sow, how to add an argument to the command-line of an application?
There are no answers at this time