Partager via


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_NONE
      Calls LoadTypeLib without the registration process enabled.
  • 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

See Also

Reference

Automation Functions
LoadTypeLib