title: How do I catch and handle `_com_error`?
body: <p>I currently have  code such as this</p>
  
  <pre><code>IAcctMaintPtr acct(__uuidof(AcctMaint));
  acct-&gt;GetAccountList(q);
  </code></pre>
  
  <p>Now this code requires an external application to be running otherwise after the first statement I get an exception stating</p>
  
  <blockquote>
    <p>Unhandled exception at 0x7739c41f (KernelBase.dll) in myapp.exe: Microsoft C++ exception: _com_error at memory location 0x003ccefc..</p>
  </blockquote>
  
  <p>I tried to <code>catch( const std::exception&amp; )</code> but that doesn't seem to work - the exception is not being caught.</p>
  
  <p>Any suggestion on how I could catch this exception ?</p>