Visual Basic: RDO Data Control

QueryComplete Event

See Also    Example    Applies To

Occurs after the query of an rdoResultset returns the first result set

Syntax

Private Subobject**.QueryComplete**(Query as rdoQuery, ErrorOccured as Boolean)

The QueryComplete event syntax has these parts:

Part Description
object An object expression that evaluates to an object in the Applies To list.
Query An object expression that evaluates to an rdoQuery object whose query has just completed.
ErrorOccured A Boolean expression indicating if an error occurred while processing the query.

The settings for ErrorOccurred are:

Setting Description
True An error occurred during query processing.
False An error did not occur during query processing.

Fired when a query has completed. You can use this event as a notification that the result set is now ready for processing.

The ErrorOccured parameter indicates if there was an error while the query was executing. If this flag is True, you should check the rdoErrors collection for more information.

The QueryComplete event fires for all queries execute on this rdoConnection. This includes those queries executed via the OpenResultset or Execute methods, as well as those executed from an associated rdoQuery object. The Query argument is an object reference indicating which query just finished executing. Using this argument, you can write a single event handler for all queries on the connection, but still customize the handler for specific queries. When executing queries against the rdoConnection object itself, RDO creates an rdoQuery object internally, and a reference to this internal rdoQuery is passed as the Query argument.

This event should be used instead of polling the StillExecuting property to test for completion of OpenResultset or Execute method queries.