Notifies the consumer of the first change to a row or of any change that affects the entire row.
HRESULT OnRowChange ( IRowset *pRowset, DBCOUNTITEM cRows, const HROW rghRows[], DBREASON eReason, DBEVENTPHASE ePhase, BOOL fCantDeny);
Parameters
After this method returns, the reference count of these rows will be unchanged unless the consumer explicitly changes them. This is different from other methods that return rows to the consumer, in which the provider explicitly increments the reference counts. Therefore, if the consumer wants to guarantee that these row handles are valid after this method returns, it must call IRowset::AddRefRows for these rows while it is processing this method.
Return Code
Comments
Possible reasons are any of the DBREASON_ROW_* reasons.
Phases occur as documented for the DBREASON enumeration. Prior values remain in the row up to and including the DBEVENTPHASE_ABOUTTODO phase. The new value is visible with the DBEVENTPHASE_SYNCHAFTER or later phases.
When a DBREASON_ROW_ACTIVATE notification is triggered, the array of row handles passed to IRowsetNotify::OnRowChange is exactly the order in which the rows were fetched.
Unless the consumer returns S_FALSE, the provider continues the operation. This is true even if the consumer returns E_FAIL or any other error code.
When calling IRowsetNotify::OnRowChange with DBREASON_ROW_INSERT, providers should assign and send the same valid row handle for all phases because consumers can use row handles to match notifications. This assumption was unstated prior to OLE DB 2.6, and for maximum interoperability, consumers should make allowances for DBEVENTPHASE_OKTODO and DBEVENTPHASE_ABOUTTODO phases for NULL row handles.
IRowsetNotify::OnFieldChange | IRowsetNotify::OnRowsetChange