ResetArgElements PowerScript function
Description
Clears the argument list.
Controls
Window ActiveX controls
Syntax
|
1 |
<span>activexcontrol</span>.<span>ResetArgElements</span> ( ) |
|
Argument |
Description |
|---|---|
|
activexcontrol |
Identifier for the instance of the PowerBuilder |
Return Values
Integer. Returns 1 if the function succeeds
and -1 if an error occurs.
Usage
Call this function after calling InvokePBFunction or TriggerPBEvent to
clear the argument list.
If you populate the argument list with SetArgElement,
you should call this function to clear the argument list after using InvokePBFunction or TriggerPBEvent to
call an event or function with arguments.
Examples
This JavaScript example calls the ResetArgElements function:
|
1 |
... |
|
1 |
retcd = PBRX1.TriggerPBEvent(theEvent, numargs); |
|
1 |
rc = parseInt(PBRX1.GetLastReturn()); |
|
1 |
IF (rc != 1) { |
|
1 |
alert("Error. Empty string."); |
|
1 |
} |
|
1 |
PBRX1.<span>ResetArgElements</span>(); |
|
1 |
... |
This VBScript example calls the ResetArgElements function:
|
1 |
... |
|
1 |
retcd = PBRX1.TriggerPBEvent(theEvent, numargs) |
|
1 |
rc = PBRX1.GetLastReturn() |
|
1 |
IF rc <> 1 THEN |
|
1 |
msgbox "Error. Empty string." |
|
1 |
END IF |
|
1 |
PBRX1.<span>ResetArgElements</span>() |
|
1 |
... |