how to time limit C# foreach loop to execute an iteration with max time limit
<p>how to time limit C# foreach loop, every iteration should run normally and go to next iteration when the previous one take longer than 30sec.</p>

<p>used stopwatch, timer...but those are allowing to run iteration every 30 sec, can anyone help...</p>