You can trigger debugging using the just-in-time debugging feature. When this is enabled, an application stops when a run-time error occurs or if the code contains CBL_DEBUGBREAK and CBL_DEBUG_START library routines, and Visual Studio starts the debugger.
The debugger attaches to the failed process and the relevant line of source is highlighted. You can view the contents of data items and memory and step through the code using the standard debugging techniques.
By default, when just-in-time debugging launches Visual Studio, only the source file is opened and no associated project. This means that there are no background parse errors or warnings shown, and editing the source is impossible.