MDAC 2.5 SDK - OLE DB Programmer's Reference
Chapter 20: OLE DB Core Components
The interfaces in this section are implemented by the Data Link core component. The full API reference entries for these interfaces can be found in the COM documentation in the Platform SDK, which is included in the MSDN Library. Below are implementation notes specific to the Data Link core component.
Methods not implemented on these interfaces will return E_NOTIMPL from a call to the method. If the method is a part of the interface but is not supported, it is not listed below.
This method is used by the provider's property page to tell the Data Link core component that a value on the page has been updated. This should be called whenever the user changes the value of one of the controls on the property page.
HRESULT OnStatusChange(
DWORD dwFlags);
Parameters
dwFlags
[in]
Flags to indicate what changes have occurred to the property page.
Flag | Meaning |
PROPPAGESTATUS_DIRTY | Values in the page have changed. |
PROPPAGESTATUS_CLEAN | Values in the page have not changed. |
PROPPAGESTATUS_VALIDATE | Now is an appropriate time to apply changes. |
Returns the locale identifier so the property page can adjust itself to country-specific settings.
This method is provided so that the provider can determine what language settings are being used. The provider should then use that locale when setting up the pages for display.
HRESULT GetLocaleID(
LCID * pLocaleID);
Parameters
pLocaleID
[out]
Pointer to locale identifier.
Passes a keystroke to the property frame for processing.
This method is implemented by the Data Link user interface so that the provider page, upon receiving a keystroke it doesn't handle, can pass the keystroke on to the property sheet for processing.
HRESULT TranslateAccelerator(
LPMSG pMsg);
Parameters
pMsg
[in]
Pointer to the MSG structure to be processed.
Within the provider's IPersistPropertyBag::Load implementation, the provider page is to use IPropertyBag::Read to extract the properties used to load the controls on the page being displayed.
HRESULT Read(
LPCOLESTR pszPropName,
VARIANT * pVar,
IErrorLog * pErrorLog);
Parameters
pszPropName
[in]
Pointer to the name of the property to read. Cannot be NULL.
pVar
[in]
Pointer to the caller-initialized VARIANT that is to receive the property value on output.
pErrorLog
[in]
Currently unused. Should be set to NULL.
When the provider receives a request to IPersistPropertyBag::Save, it calls the Write method on the Data Link core component IPropertyBag implementation to save the individual properties that were changed while the page was active.
HRESULT Write(
LPCOLESTR pszPropName,
VARIANT * pVar);
Parameters
pszPropName
[in]
Pointer to the name of the property to write. Cannot be NULL.
pVar
[in]
Pointer to the caller-initialized VARIANT that holds the property value to save.
The IPropertyPage2 interface is an extension to IPropertyPage to support initial selection of a property on a page.
Specifies in dispID the property's control located on the property page that will receive the focus when the page is activated.