PowerTip: Find Information About ErrorActionPreference

PowerTip: Find Information About ErrorActionPreference

  • Comments 1
  • Likes

Summary: Find information, beyond the basics, for the Windows PowerShell variable ErrorActionPreference.

Hey, Scripting Guy! Question How can I use Windows PowerShell to see information, beyond only the value, for the variable ErrorActionPreference?

Hey, Scripting Guy! Answer Use the Get-Variable cmdlet and pipe the results to the Format-List cmdlet:

Get-Variable ErrorActionPreference | Format-List *

Note  When you use the *variable cmdlets, you do not specify the initial dollar sign.
So it is represented as ErrorActionPreference not $ErrorActionPreference.

Your comment has been posted.   Close
Thank you, your comment requires moderation so it may take a while to appear.   Close
Leave a Comment