Summary: Set a Windows PowerShell breakpoint based on a variable.
How can I enter the Windows PowerShell debugger when a particular variable is accessed in a specific
Windows PowerShell script?
Set a breakpoint and specify a particular variable and script, for example:
Set-PSBreakpoint -Variable num -Mode write -Script C:\FSO\BadScript.ps1