title: Adding a timeout to a process in a console application
body: <p>I wrote a console application that finds some Excel files, opens them up and refreshes the data. Once in awhile Excel will crash or hang and I want to be able to be able to skip that file and keep going on to the next file. I think that setting a timeout that kicks in after a few minutes and moves on to the next file. </p>
  
  <p>I saw this question: <a href="https://stackoverflow.com/questions/57615/how-to-add-a-timeout-to-console-readline">How to add a Timeout to Console.ReadLine()?</a> but I'm not sure that it's the right answer. </p>
  
  <p>Here's some pseudocode of what I'm thinking:</p>
  
  <pre><code>Set timeout variable
  Refresh file
  If timeout has been exceeded, go to the next file.
  </code></pre>
  
  <p>Can anyone point me in the right direction?</p>