say I have 50 lines of ps code I want to run, a few examples below, I dont want to open 50 windows and run them separately, is there a way to just go to the next line once the first one is done?
.\Get-MessageTraceBySubject.ps1 -Days 3 -Subject "*favor*" -OutputFile c:\temp\favor-$(get-date -f yyyy-MM-dd).csv
.\Get-MessageTraceBySubject.ps1 -Days 3 -Subject "*errand*" -OutputFile c:\temp\errand-$(get-date -f yyyy-MM-dd).csv
.\Get-MessageTraceBySubject.ps1 -Days 3 -Subject "*greeting*" -OutputFile c:\temp\greeting-$(get-date -f yyyy-MM-dd).csv
tried -wait it failed
Yes, just create a txt file that contains the keywords you are looking for and then loop through the results.