Language Reference Guide : Events : ExtClassEvent Event
 
Share this page          
ExtClassEvent Event
The ExtClassEvent event is triggered by external objects such as Active X controls.
This event has the following syntax:
on extclassevent [fieldname] ['eventname'] [([parameterlist])]
This event has the following parameters:
fieldname
Specifies an optional field name if you specify the event block in a field script
eventname
Specifies a string with the external event name, surrounded by quotes
parameterlist
Defines named parameters passed in from the external object raising the event
The event block script can then use these parameters as local variables. The parameterlist is specified as follows:
variablename = type{,variablename = type}
variablename
Specifies a named parameter defined by the event
This event has no attributes.
Usage: External class events are raised by external objects such as Active X controls. OpenROAD does not handle external events synchronously. This means that OpenROAD does not execute the associated event block before notifying the external object that the event has been received and handled. This means that events that use parameters to pass information back to the external object are not completely supported.
You can specify this event in either a frame or field script. If you specify the event name, OpenROAD executes the event block when the frame receives that particular external class event. If you do not specify an event name, OpenROAD executes the block when the frame receives any external class event.
If a field name is specified, OpenROAD executes the event block when the frame receives that particular external class event only if the event was raised by the external object with the specified field name.
If a parameter list is specified, OpenROAD passes into the event block any parameters associated with the event.
The following is an example of handling external class events:
initialize()=
begin
          curframe.flush();
          browser1.navigate('http:\\www.actian.com');
end
on extclassevent 'StatusTextChange' (text = varchar(128)) =
begin
          StatusTextfield1 = text;
end