Post
PowerScript function
Description
Adds a message to the message queue for a window, either a
PowerBuilder window or window of another application.
Syntax
|
1 |
Post ( handle, message#, word, long ) |
|
Argument |
Description |
|---|---|
|
handle |
A long whose value is the system handle of a window (that |
|
message# |
An UnsignedInteger whose value is the system message |
|
word |
A long whose value is the integer value of the message. If |
|
long |
The long value of the message or a string. |
Return value
Boolean. If any argument’s value is null, Post returns null.
Usage
Use Post or Send when you want to trigger system events that are not
PowerBuilder-defined events. Post is asynchronous; it adds a message to
the end of the window’s message queue. Send is synchronous; its message
triggers an event immediately.
To obtain the handle of a PowerBuilder window, use the Handle function.
To trigger PowerBuilder events, use TriggerEvent or PostEvent. These
functions run the script associated with the event. They are easier to
code and bypass the messaging queue.
When you specify a string for long, Post stores a copy of the string
and passes a pointer to it.
Examples
This statement scrolls the window w_date down one page after all the
previous messages in the message queue for the window have been
processed:
|
1 |
Post(Handle(w_date), 277, 3, 0) |
See also