Oracle® Objects for OLE C++ Class Library Developer's Guide 10g Release 2 (10.2) Part Number B14308-01 |
|
Applies To
Description
The StatusChange method is called by a dynaset when that dynaset's status changes.
Usage
oresult StatusChange(int statustype)
Arguments
statustype |
statustype will have one of the values: OADVISE_FOUNDLAST - dynaset has come to last record. |
You do not call StatusChange; rather, the StatusChange method of your OAdvise subclass is called.
When you subclass OAdvise, you can override the StatusChange method. After an instance of your OAdvise subclass is attached to a dynaset (by way of the OAdvise::Open method), your instance receives calls to its StatusChange method. Use a StatusChange method to perform processing when a dynaset's status has changed.
In the current release, the only status change is that which occurs when the dynaset finds the last record. This can occur on a MoveLast or on a MoveNext that attempts to move past the last record, or on a GetRecordCount. The unoverridden StatusChange method does nothing.
Return Value
An oresult indicating whether the operation succeeded (OSUCCESS) or not (OFAILURE).
Example
This example notifies the application that the entire dynaset has been downloaded to the client.
void YourOAdvise::StatusChange(int statustype)
{
if (statustype == OADVISE_FOUNDLAST)
m_appcontext->HaveAllRecords();
return;
}