I learnt this from my manager.
DebugBreak is powerful tool you can use when debugging applications. I had this scenario where I need to use a java app which was internally calling C++ methods, basically JNI functions.
The error in question was in the C++ side, so not really an option to use debugger. Therefore I went inside the C++ code, and set this.
Compiled the code. Also for better debugging, you need to turn on the debug symbols. This can be turned on in project settings[program database].
Then go into the visual studio and attach to the process. In this case, i attached it to the java.exe.
Then when there was an exception, I was able to go into the code and retrieve the error codes.