IOleLink::SetUpdateOptions
Specifies how often a linked object should update its cached data.
HRESULT SetUpdateOptions(
DWORD dwUpdateOpt
| //Update option
|
);
|
|
Parameter
dwUpdateOpt
[in] Specifies how often a linked object should update its cached data. The
legal values for
dwUpdateOpt are taken from the enumeration
OLEUPDATE. For information on the
OLEUPDATE enumeration, see the "Data Structures" section.
Return Values
S_OK
The update option was successfully set.
E_INVALIDARG
The
dwUpdateOpt value is invalid.
Comments
Notes to Callers
Your container application should call
IOleLink::SetUpdateOptions when the end user changes the update option for a linked object.
The end user selects the update option for a linked object using the Links
dialog box. If you use the
OleUIEditLinks API function to display this dialog box, you must implement the
IOleUILinkContainer interface. The dialog box calls your
IOleUILinkContainer::SetLinkUpdateOptions method to specify the update option chosen by the end user. Your
implementation of this method should call the
IOleLink::SetUpdateOptions method to pass the selected option to the linked object.
Notes on Provided Implementation
The default update option is OLEUDPATE_ALWAYS. The linked object's
implementation of
IPersistStorage::Save saves the current update option.
If OLEUDPATE_ALWAYS is specified as the update option, the linked object
updates the link's caches in the following situations:
- When the update option is changed from manual to automatic, if the link source
is running.
- Whenever the linked object binds to the link source.
- Whenever the link source is running and the linked object's IOleObject::Close, IPersistStorage::Save, or IAdviseSink::OnSave implementations are called.
For both manual and automatic links, the linked object updates the cache
whenever the container application calls
IOleObject::Update or
IOleLink::Update.
See Also
IOleObject::Update,
IOleLink::GetUpdateOptions,
IOleLink::Update,
IOleUILinkContainer,
OleUIEditLinks
- Software for developers
-
Delphi Components
.Net Components
Software for Android Developers
- More information resources
-
MegaDetailed.Net
Unix Manual Pages
Delphi Examples
- Databases for Amazon shops developers
-
Amazon Categories Database
Browse Nodes Database