HRESULT LoadRegTypeLib(
REFGUID rguid,
unsigned short wVerMajor,
unsigned short wVerMinor,(一般默认为0)
LCID lcid, (一般默认为0)
ITypeLib FAR* FAR* pptlib
);
参数
rguid :类型库ID
wVerMajor:主版本号
wVerMinor:副版本号
lcid :语言代码
pptlib:指向类型库的指针的指针
返回值:
返回一个句柄.
该句柄的值如下:
S_OK Success.
E_OUTOFMEMORY Out of memory.
E_INVALIDARG One or more of the arguments is invalid.
TYPE_E_IOERROR The function could not read from the file.
TYPE_E_INVALIDSTATE The type library could not be opened.
TYPE_E_INVDATAREAD The function could not read from the file.
TYPE_E_UNSUPFORMAT The type library has an older format.
TYPE_E_UNKNOWNLCID The passed in LCID could not be found in the OLE-supported DLLs.
TYPE_E_CANTLOADLIBRARY The type library or DLL could not be loaded.
Other return codes All FACILITY_STORAGE and system registry errors can also be returned
阅读(2361) | 评论(0) | 转发(0) |