title: Catching unexpected errors in PowerShell
body: <p>So I've been doing my error handling in Powershell with <code>Try/Catch</code> so far and whenever an error occurs, it gets written to a log file.</p>
  
  <p>Now how could I handle unexpected errors? Should I just put the whole script code in a <code>Try/Catch</code> block or is there a better method to do this?</p>
  
  <p>Thanks for any help.</p>