Welcome › Forums › General PowerShell Q&A › non-terminating error
This topic contains 1 reply, has 2 voices, and was last updated by
is there a way to log a non-terminating error without forcing the script to stop with '-ErrorAction Stop'
You can use the -ErrorVariable parameter, and check for any records in that variable after the command exits:
Do-Something -ErrorVariable myErrors
# handle errors
The topic ‘non-terminating error’ is closed to new replies.