| description | Learn more about: CDBPropSet Class | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| title | CDBPropSet Class | ||||||||||||||||||||
| ms.date | 11/04/2016 | ||||||||||||||||||||
| f1_keywords |
|
||||||||||||||||||||
| helpviewer_keywords |
|
||||||||||||||||||||
| ms.assetid | 54190149-c277-4679-b81a-ef484d4d1c00 |
Inherits from the DBPROPSET structure and adds a constructor that initializes key fields as well as the AddProperty access method.
class CDBPropSet : public tagDBPROPSETHeader: atldbcli.h
| Name | Description |
|---|---|
| AddProperty | Adds a property to the property set. |
| CDBPropSet | Constructor. |
| SetGUID | Sets the guidPropertySet field of the DBPROPSET structure. |
| Name | Description |
|---|---|
| operator = | Assigns the contents of one property set to another. |
OLE DB providers and consumers use DBPROPSET structures to pass arrays of DBPROP structures. Each DBPROP structure represents a single property that can be set.
Adds a property to the property set.
bool AddProperty(DWORD dwPropertyID,
constVARIANT& var,
DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED) throw();bool AddProperty(DWORD dwPropertyID,
LPCSTR szValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED) throw();bool AddProperty(DWORD dwPropertyID,
LPCWSTR szValue,DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED) throw();bool AddProperty(DWORD dwPropertyID,
bool bValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED) throw();bool AddProperty(DWORD dwPropertyID,
BYTE bValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED);bool AddProperty(DWORD dwPropertyID,
short nValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED);bool AddProperty(DWORD dwPropertyID,
long nValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED);bool AddProperty(DWORD dwPropertyID,
float fltValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED);bool AddProperty(DWORD dwPropertyID,
double dblValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED) throw();bool AddProperty(DWORD dwPropertyID,
CY cyValue, DBPROPOPTIONS propoptions = DBPROPOPTIONS_REQUIRED) throw();dwPropertyID
[in] The ID of the property to be added. Used to initialize the dwPropertyID of the DBPROP structure added to the property set.
var
[in] A variant used to initialize the property value for the DBPROP structure added to the property set.
szValue
[in] A string used to initialize the property value for the DBPROP structure added to the property set.
bValue
[in] A BYTE or boolean value used to initialize the property value for the DBPROP structure added to the property set.
nValue
[in] An integer value used to initialize the property value for the DBPROP structure added to the property set.
fltValue
[in] A floating-point value used to initialize the property value for the DBPROP structure added to the property set.
dblValue
[in] A double-precision floating-point value used to initialize the property value for the DBPROP structure added to the property set.
cyValue
[in] A CY currency value used to initialize the property value for the DBPROP structure added to the property set.
true if the property was successfully added. Otherwise, false.
The constructor. Initializes the rgProperties, cProperties, and guidPropertySet fields of the DBPROPSET structure.
CDBPropSet(const GUID& guid);
CDBPropSet(const CDBPropSet& propset);
CDBPropSet();guid
[in] A GUID used to initialize the guidPropertySet field.
propset
[in] Another CDBPropSet object for copy construction.
Sets the guidPropertySet field in the DBPROPSET structure.
void SetGUID(const GUID& guid) throw();guid
[in] A GUID used to set the guidPropertySet field of the DBPROPSET structure.
This field can be set by the constructor as well.
Assigns the contents of one property set to another property set.
CDBPropSet& operator =(CDBPropSet& propset) throw();OLE DB Consumer Templates
OLE DB Consumer Templates Reference
CDBPropIDSet Class
DBPROPSET Structure
DBPROP Structure