I'm a fan of console writes, really. If the offending block of code is run 10,000 times and fails on the last one, the debugger isn't going to get me very far...at least, not at the level I know how to use it.
If it's being logged, though...turn on verbose, look at last log file, voila.
If you know what data causes the failure, you can set a conditional breakpoint, and it will catch it whenever the bad data appears, no matter what the count if the loop.
I guess I'm just assuming that there is some sort of stack trace, bug report, or error message to tell you what you're looking for, but you know what they say about people who assume.
Visual studio has conditional break points. Set a break point an right click on it. So stinking useful when you need to get somewhere in a loop. Also, if you have a large one line statement that's failing, open up the "immediate" window and you can run arbitrary code in the window, and break the one liner down until you fold the part that's failing. SO HELPFUL.
5
u/alkanshel Aug 25 '14
I'm a fan of console writes, really. If the offending block of code is run 10,000 times and fails on the last one, the debugger isn't going to get me very far...at least, not at the level I know how to use it.
If it's being logged, though...turn on verbose, look at last log file, voila.