i have used this example to be able to run a script through a java program to simply get a text output (it works as required).
String command = "powershell.exe \"C:\\Users\\--\\--\\script.ps1\" ";
Process powerShellProcess = Runtime.getRuntime().exec(command);
i am looking at furthering my script within java to use said script on multiple pages, with the only change being an address variable ideally passed through from a loop within eclipse. i have $address
variable in my script.ps1 file where it is currently declared at the top of my powershell script - ideally i want to be able to declare $address
in eclipse.
Is this possible? or would i need to adjust the script another way.
Thank you