So I have a tool I am working on for a team in the company I work for. I get the general concept but I am running into dumb issues which I am sure are due to my own ignorance.
I would like to start a continuos ping session in an external window. I can get it to work for a regular session, 4 results and done then the window auto closes. When I try to pass the -t switch is when powershell farts out an error. The command goes like this:
Start-Process -FilePath ping.exe -ArgumentList $WksTxtBox1.Text -t
It works if it doesn’t have the -t switch:
Start-Process -FilePath ping.exe -ArgumentList $WksTxtBox1.Text
I have been banging my head against the display trying to figure this out and I know it must be something really simple to get but for the life of me I cannot.
The other issue I am having is similar in that switches are ruining my powershell sanity.
What I have is this:
Start-Process -FilePath powershell.exe -ArgumentList -noexit -command enter-pssession -computername $WksTxtBox2.Text
I have tried it with quotes before -noexit and after .Text. But that obviously did not work.
What am I missing? It has to be something simple but I cannot figure it out.
Thank you muchly for your help!