ICOMAdminCatalog2::AliasComponent method (comadmin.h)
Creates an alias for an existing COM+ component.
Syntax
HRESULT AliasComponent(
[in] BSTR bstrSrcApplicationIDOrName,
[in] BSTR bstrCLSIDOrProgID,
[in] BSTR bstrDestApplicationIDOrName,
[in] BSTR bstrNewProgId,
[in] BSTR bstrNewClsid
);
Parameters
[in] bstrSrcApplicationIDOrName
The application ID or name of the source application containing the component.
[in] bstrCLSIDOrProgID
The class ID or program ID of the component for which an alias is created.
[in] bstrDestApplicationIDOrName
The application ID or the name of the destination application that contains the alias. If this argument is NULL or an empty string, the alias is created within the source application.
[in] bstrNewProgId
The program ID of the alias.
[in] bstrNewClsid
The class ID of the alias. If this argument is NULL or an empty string, a new, unique class ID is assigned.
Return value
This method can return the standard return values E_INVALIDARG, E_OUTOFMEMORY, E_UNEXPECTED, and E_FAIL, as well as the following values.
Return code | Description |
---|---|
|
The method completed successfully. |
|
At least one of the named applications exists in multiple partitions. To avoid this error, use application IDs instead of names. |
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | comadmin.h |