ITcLibraryManager2::GetLibraryIecDeclarationEx
Reads a library's IEC declaration and also allows you to control namespace output via bUseNamespaceForMembers. If the resolution is successful, the declaration is returned as BSTR.
Signature
HRESULT GetLibraryIecDeclarationEx(BSTR bstrLibraryId, VARIANT_BOOL bTryToLoad, VARIANT_BOOL bUseNamespaceForMembers, BSTR* pIecDeclaration);
Parameter
|
Name |
Type |
Description |
|---|---|---|
|
bstrLibraryId |
BSTR |
[in] Unique library ID of the library to be resolved. |
|
bTryToLoad |
VARIANT_BOOL |
[in, defaultvalue(-1)] Controls whether loading is attempted during lookup ( |
|
bUseNamespaceForMembers |
VARIANT_BOOL |
[in, defaultvalue(-1)] Controls whether members are output with a namespace in the declaration. |
Return value
|
Name |
Type |
Description |
|---|---|---|
|
pIecDeclaration |
BSTR* |
[out, retval] IEC declaration of the library as a string. |
|
(HRESULT) |
HRESULT |
|
Error codes
-
E_POINTER:pIecDeclarationisNULL. -
ADS_E_NOTFOUND: The library forbstrLibraryIdwas not found. -
E_NOINTERFACE: No object is available with theITcLibraryManager2.