Connection Information

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Connection Type

Add breakpoints in application scripts – PB Docs 2019 – PowerBuilder Library

Add breakpoints in application scripts – PB Docs 2019

Add
breakpoints in application scripts

Where you are

> Add breakpoints
in application scripts

Run in debug
mode

Set a watch and a
conditional breakpoint

Now you open the Debugger and add breakpoints to examine the
behavior of the login and Customer windows. When PowerBuilder runs the
application in debug mode, it stops just before executing a line
containing a breakpoint.

When you insert breakpoints in a script, you should select lines
that contain executable statements. If you try to set a breakpoint in
variable-declaration lines, comment lines, or blank lines, PowerBuilder
sets the breakpoint at the next executable line.

  1. Click the Debug button (zzdebug.gif) in the PowerBar.

    PowerBuilder opens the Debugger. There are three stacks of
    tabbed panes in the default view layout scheme. The Source view is
    visible in a single pane at the top left of the Debug window. The
    Source Browser view is open in the pane at the top right.

    If the Debug window looks different

    If you have opened the Debug window before and opened, moved,
    or closed any views, your display may look different. To restore the
    default view layout scheme, select View>Layouts>Default from
    the menu bar.

    pbc15w01.gif

    The source code for the application Open event displays in the
    Source view at top left. If it does not display, expand the
    Application node in the Source Browser view’s tree view and
    double-click the Open event under the pbtutor application.

  2. In the Source view, double-click the line containing the
    following assignment statement:

    A black breakpoint symbol displays at the start of the line to
    show that a breakpoint has been set on the statement.

    pbc15w02.gif
  3. Expand the following node in the Source Browser view:
    Windows>w_welcome>cb_ok

    The Source Browser view lists only events that have been coded.
    The only event for the login window OK button is the Clicked
    event.

  4. Double-click the Clicked event for the cb_ok button in the
    Source Browser view.

    The code for the Clicked event displays in the Source
    view.

  5. Double-click the following line:

    A breakpoint symbol displays at the start of the line.

    pbc15w03.gif
  6. Double-click w_master_detail_ancestor in the Source Browser
    view.

  7. Double-click dw_master, then rowfocuschanged.

    PowerBuilder displays the script for the RowFocusChanged event
    of the dw_master DataWindow control in the Source view.

  8. Double-click this line:

    A breakpoint symbol displays at the start of the line.

  9. Select the Breakpoints tab in the lower-right stack.

    pbc15w04.gif

    You should see the breakpoints you set in the Breakpoints view.
    To complete this lesson, you need to have these breakpoints set
    correctly.

If you have additional breakpoints

You can clear any excess breakpoints using the pop-up menu in the
Breakpoints view.


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x