When the desire to define the interface as follows:
[Id (1), helpstring ("method SearchCust")] HRESULT SearchCust ([in] BSTR bstrcustid, [out, retval] _Recordset ** ptr);
As used _Recordset type, it is necessary
importlib ("C: Program FilesCommon FilesSystemADOMSADO15.DLL");
So the idl file should be rewritten as follows:
/ / FindCust.idl: IDL source for FindCust.dll
/ /
/ / This file will be processed by the MIDL tool to
/ / Produce the type library (FindCust.tlb) and marshalling code.
import "oaidl.idl";
import "ocidl.idl";
[
uuid (B32A7D72-12D4-11D5-AC09-00A0247A8577),
version (1.0),
helpstring ("FindCust 1.0 Type Library")
]
library FINDCUSTLib / / Library to manually advance the
(
importlib ("stdole32.tlb");
importlib ("stdole2.tlb");
/ / MODIFY HERE
importlib ("C: Program FilesCommon FilesSystemADOMSADO15.DLL");
[
object,
uuid (B32A7D7F-12D4-11D5-AC09-00A0247A8577),
dual,
helpstring ("ISearch Interface"),
pointer_default (unique)
]
interface ISearch: IDispatch
(
[Id (1), helpstring ("method SearchCust")] HRESULT SearchCust ([in] BSTR bstrcustid, [out, retval] _Recordset ** ptr);
);
[
uuid (B32A7D81-12D4-11D5-AC09-00A0247A8577),
helpstring ("_ISearchEvents Interface")
]
dispinterface _ISearchEvents
(
properties:
methods:
);
[
uuid (B32A7D80-12D4-11D5-AC09-00A0247A8577),
helpstring ("Search Class")
]
coclass Search
(
[Default] interface ISearch;
[Default, source] dispinterface _ISearchEvents;
);
);
Recommended links:
How to quick Cash flow statement the two main forms
Registry Tools Storage
"Mount & Blade" skill POINT changes
Mkv converter free
ASSEMBLY language of high-level language features
Wizard Icon Tools
Lists Vertical Market Apps
CONVERT mkv
matroska video File
RECOMMEND Audio Speech
Got hit by Baidu PPC
Correct understanding of the importance of examinations and the usual accumulation of [2]
Convert mp4 to 3gp free
WinRAR sub-normal volume icon shows
Who won the dream of the vast CULTURAL Kai
C language programming style
No comments:
Post a Comment