Campbell Ritchie wrote:To go on from what MS said: that sort of thing is using Exceptions for flow control. In fact, you would be using the Exceptions as a substitute for if statements, which is by no means good design.
Um, I wasn't talking about using exceptions for flow control at all. I was talking about the opposite, using flow control to prevent exceptions. And I don't think anything that the original poster talked about implied using exceptions for flow control. Than again, I'm not sure what the original poster meant, if it wasn't what I said, so maybe they could explain the goal better.
Vinod Tiwari wrote:like Mike and Campbell explained it would not be a wise idea/design to put multiple checks to avoid the exception.
That sounds like the opposite of what I said.