WSError event
Description
Occurs when an error is
returned for a DataWindow using a Web service data source. The error
can occur during any of the following operations: connect, retrieve,
delete, insert, update, or disconnect.
PowerBuilder event information
Event ID: pbm_dwnwserror
|
Argument |
Description |
|---|---|
|
operation |
String for the type |
|
rownum |
Long for the row |
|
buffername |
String for the name |
|
wsinfo |
String for the WSDL |
|
method |
String for the name |
|
errormessage |
String for the exception |
Return Values
Set the return code to affect the outcome of the event:
-
0 Display the error
message -
1 Do not display the error message
For information on setting the return code in a particular
environment, see “About return values for
DataWindow events”.
Usage
Because you cannot use the DBError event with a Web Service
DataWindow, you must use the WSError event to obtain any error information.
Examples
The following code in a WSError event script causes
information about an error to display in a message box:
|
1 |
MessageBox("Error event", "Error in row " &    |
|
1 |
   + string(rownum) + ", Occurred during " + method & |
|
1 |
   + "; the cause of the error is: "+ errormessage) |