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

HALT – PB Docs 125 – PowerBuilder Library

HALT – PB Docs 125

HALT

Description

Terminates an application.

Syntax

Usage

When PowerBuilder encounters Halt without
the keyword CLOSE, it immediately terminates
the application.

When PowerBuilder encounters Halt with
the keyword CLOSE, it immediately executes the
scripts for application Close event and for the CloseQuery, Close, and
Destructor events on all instantiated objects before terminating
the application. If there are no scripts for these events, PowerBuilder
immediately terminates the application.

You should not code a HALT statement in
a component that will run in a server environment. When a PowerBuilder
component is running in a server such as EAServer or J2EE, and a HALT statement
is encountered, instead of aborting the application, which is in
this case the server itself, the PowerBuilder VM throws a runtime
error and continues. The container is responsible for managing the
lifecycle of the component. In EAServer, the error message is written
to the Jaguar log, even if the runtime error causes a transaction
rollback and the transaction is overridden by a new transaction.

Examples

[Example 1]

This statement stops the application if the user enters a
password in the SingleLineEdit named sle_password that
does not match the value stored in a string named CorrectPassword:

[Example 2]

This statement executes the script for the Close event for
the application before it terminates the application if the user
enters a password in sle_password that
does not match the value stored in the string CorrectPassword:


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