The debugger is an
implementation of the Visual Studio debugger. If you are familiar with either the PowerBuilder Classic or the Visual Studio
debugger, you will notice both similarities and differences in the debugger.
PowerBuilder .NET debugger for WPF
applications and .NET targets only – the PowerScript debugger for
PowerBuilder .NET is used only to
debug PowerScript code in WPF applications within the IDE. It is not used to
debug other types of applications, such as WPF browser, Windows Forms, or Web Forms
applications, or WPF and .NET applications that you create outside of
PowerBuilder .NET.
You cannot
attach the debugger to the process of an application running outside of the
IDE, or perform remote debugging.
Only debug version can be debugged – the release version cannot be debugged. If a debug version does not exist, the debugger fails. This is not related to the build type set in the Project painter.
IDE is read-only during debugging – in PowerBuilder .NET, all windows in
the IDE become read-only when you start the debugger. To edit a script, stop the debugger to return to design mode.
Breakpoints enhanced – PowerBuilder .NET includes several
breakpoint features from the Visual Studio debugger: in addition to breaking
when a condition expression is true, you can break when it is false or when it
changes. You can associate a custom action with a breakpoint using a Visual
Studio tracepoint.
Edit Breakpoints dialog box replaced by Breakpoints window – the Breakpoints window is where you view and manage breakpoints.
Exceptions handled as in the Visual Studio debugger – the PowerBuilder .NET debugger
implements exception handling from Visual Studio, which is different in some
details from exception handling in PowerBuilder Classic.
Run to a specified function on the call stack – the application executes up to the first line of the specified function. This
feature is implemented from the Visual Studio debugger.
PowerBuilder Classic debugger
features not implemented –
PowerBuilder Classic debugger
features not impemented in
PowerBuilder .NET include:
- Just-in-time debugging
- Objects in memory view
- Source Browser and Source History view
Visual Studio debugger features not implemented – Visual Studio debugger features not implemented in
PowerBuilder .NET include:
- Watchpoints
- Edit and Continue
- Just-in-Time debugging
- Debugging multithreaded applications
Variable views replaced by Visual Studio debugger windows – variable views in
PowerBuilder Classic are replaced by these Visual Studio variable windows:
- All Variables – the All Variables window displays local variables in the procedure or function you are currently executing, as well as instance, global, and shared variables. The debugger automatically populates this window.
- Autos – the Autos window displays variables used in the current line of code
and the preceding line of code. Like the All Variables window, the Autos
window is populated automatically by the debugger.
- Watch – the Watch window is where you can add variables and expressions whose values you want
to watch.
- QuickWatch – the QuickWatch dialog box is similar to the Watch window, but
QuickWatch can display only one variable or expression at a time.
QuickWatch can be useful when you want to take a quick look at a
variable or expression without using the Watch window.
TipWatch implemented as Visual Studio DataTip – in the PowerBuilder Classic Source
view, you can place the cursor over a variable or simple expression to open a
pop-up window that shows the current value of the variable or expression. In a
PowerBuilder .NET Script window,
the same action provides a tree display of the variable's elements.