MDAC 2.5 SDK - OLE DB Providers
OSP Toolkit
Returns the read/write status of a specified column, row, cell, or data set. If one or both of iRow and iColumn have a value of -1, the read/write status is returned for the entire column, row, or complete data set.
getRWStatus uses the following enumeration:
typedef enum OSPRW {
OSPRW_READONLY = 0,
OSPRW_DEFAULT = 1,
OSPRW_READWRITE = 1,
OSPRW_MIXED = 2
};
The preceding values are defined in the following table.
Value | Meaning |
OSPRW_READONLY | Cell, row, column, or data set is read-only. |
OSPRW_DEFAULT OSPRW_READWRITE |
Cell, row, column, or data set can be modified (the default). |
OSPRW_MIXED | Cell, row, column, or data set read/write status is unknown; or row, column, or data set is of mixed status. |
HRESULT getRWStatus (
LONG iRow,
LONG iColumn,
OSPRW * prwStatus);
Parameters
iRow
[in]
Position of the specified row. A value of -1 indicates all rows.
iColumn
[in]
Position of the specified column. A value of -1 indicates all columns.
prwStatus
[out]
Enumerated value indicating the returned read/write status of a specified cell, row, column, or data set. (See above table for descriptions.)
Return Codes
S_OK
The method succeeded.
E_FAIL
A provider-specific error occurred.
Comments
If the *prwStatus is OSPRW_MIXED, most callers will treat it as read/write (OSPRW_READWRITE). A "lazy" provider should return a *prwStatus value of OSPRW_MIXED.