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

SetServerServiceClasses (obsolete) – PB Docs 2019 – PowerBuilder Library

SetServerServiceClasses (obsolete) – PB Docs 2019

SetServerServiceClasses (obsolete)

Description

Tells the server component to trigger custom events defined in user
objects for data validation. These user objects, referred to as service
classes, must be defined in the PBL or PBD containing the DataWindow
object for the server component.

Obsolete method

SetServerServiceClasses is obsolete and should not be used,
because the Web DataWindow technology is obsolete.

Applies to

DataWindow type

Method applies to

Web

Server component

Syntax

Web DataWindow server
component

Argument

Description

dwcomponent

A reference to a Web DataWindow server
component.

serviceclassnames

A string whose value is a list of PowerBuilder custom
class user objects. The user objects must be in the PBL or PBD
containing the DataWindow for the server component. Separate user
object names with a semicolon.

Return value

Returns 1 if it succeeds and -1 if a specified service class does
not exist.

Usage

The main use of service classes is to provide data validation using
server-side business logic.

Service classes implement one or more user-defined events with these
names and signatures:

The custom events can use the same return codes as the corresponding
standard DataWindow events documented in DataWindow Events By setting a
return code, a custom event can cause the event action to be canceled in
the server component.

When the standard DataWindow event occurs in the server component,
the component triggers the custom event in each of the listed service
classes. One or more of the components can implement the event. A service
class only needs to implement the events whose outcome it wants to
influence. Any of the service classes can set an event return code that
cancels the event action in the server component.

Runtime errors

Instantiated service objects run in the same objects space as the
server component. If a runtime error occurs in the service object, it
could cause HTML generation to fail.

Examples

This JavaScript example for a server-side script specifies a list of
service classes that implement events:

See also

Events:

HTMLContextApplied

DBError

RetrieveStart

RetrieveEnd

SQLPreview

UpdateStart

UpdateEnd


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