LoadTypeLibEx (Compact 2013)
3/26/2014
This function loads a type library and optionally registers it in the system registry.
Syntax
HRESULT LoadTypeLibEx(
LPCOLESTR szFile,
REGKIND regkind
ITypeLib **pptlib
);
Parameters
- szFile
The type library file.
regkind
Identifies the kind of registration to perform for the type library based on the following flags.- REGKIND_DEFAULT
Calls LoadTypeLib and registration is based on the LoadTypeLib registration rules.
- REGKING_REGISTER
Calls LoadTypeLib followed by RegisterTypeLib, which registers the type library. To unregister the type library, use UnRegisterTypeLib.
- REGKIND_NONE
Calls LoadTypeLib without the registration process enabled.
- REGKIND_DEFAULT
- pptlib
On return, a pointer to a pointer to the loaded type library.
Property Value/Return Value
Returns the HRESULT values shown in the following table.
Value |
Description |
---|---|
S_OK |
Success. |
E_OUTOFMEMORY |
Out of memory. |
E_INVALIDARG |
One or more arguments is invalid. |
TYPE_E_IOERROR |
The function could not write to the file. |
TYPE_E_INVALIDSTATE |
The type library could not be opened. |
TYPE_E_CANTLOADLIBRARY |
The type library or DLL could not be loaded. |
Exceptions
Remarks
.NET Framework Equivalent
Requirements
Header |
oleauto.h |
Library |
oleaut32.lib |