Powershell
When exception is occured, Out-Null is actually not worked, so uses
Get-ChildItem aaa >$null 2>&1
Or in Powershell 3
Get-ChildItem aaa *>$null
Batch/Dos
dir aaa >nul 2>&1
技术生活札记©Yaohui
When exception is occured, Out-Null is actually not worked, so uses
Get-ChildItem aaa >$null 2>&1
Or in Powershell 3
Get-ChildItem aaa *>$null
dir aaa >nul 2>&1