Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This method activates the connection between the linked object and the link source if the link source is already running.

Syntax

HRESULT BindIfRunning(void);

Parameters

None.

Return Value

The following table shows the return values for this method.

Value Description

S_OK

The link source was bound.

S_FALSE

The link source is not running.

CreateBindCtx, IMoniker::IsRunning, or IOleLink::BindToSourceerrors

Binding the moniker might require calling these functions, therefore, errors generated by these functions can be returned.

Remarks

You typically do not need to call IOleLink::BindIfRunning. This method is primarily called by the linked object.

The linked object's implementation of IOleLink::BindIfRunningchecks the Running Object Table (ROT) to determine whether the link source is already running.

It checks both the relative and absolute monikers.

If the link source is running, IOleLink::BindIfRunningcalls IOleLink::BindToSourceto connect the linked object to the link source.

To determine whether the platform supports this interface, see Determining Supported COM APIs.

Requirements

Header Oleidl.h, oleidl.idl
Library ole32.lib, uuid.lib
Windows Embedded CE Windows CE 3.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also