Hello, me again!
David Stuart <nospam@example.com> wrote in
news:pan.2007.03.09.22.58.07.973525@example.com:
In one visual studio project I have an IDL which defines interfaces,
for example:
[snip]
The MIDL compiler finds the first TLB just fine, but gives me a
"MIDL2039" error on the second interface, stating "interface does not
conform to [oleautomation] attribute".
[snip]
So .....
I tried to post another article with attachments that contained projects
that could easily demonstrate my problem (but for some reason they do not
show up in the group, maybe because binaries are only allowed under
alt.binaries, oh well)..
Anyway, I will cut and paste three simple IDLs which demonstrate my
problems. The names of the IDLs reflect my frustration, sorry 'bout that..
First:
====================================================================
// StupidIDL.idl : IDL source for StupidIDL
//
// This file will be processed by the MIDL tool to
// produce the type library (StupidIDL.tlb) and marshalling code.
import "oaidl.idl";
import "ocidl.idl";
import "atliface.idl";
[
uuid(7EE13ECA-63E1-4B0C-8E5D-3E773D94EA7C),
version(1.0),
helpstring("StupidIDL 1.0 Type Library")
]
library StupidIDLLib
{
importlib("stdole2.tlb");
[
object,
dual,
uuid(A2058183-5F7C-47b7-AF74-2DD763EF4E0B)
]
interface IBaseInterface : IDispatch
{
}
};
====================================================================
// StupiderIDL.idl : IDL source for StupiderIDL
//
// This file will be processed by the MIDL tool to
// produce the type library (StupiderIDL.tlb) and marshalling code.
import "oaidl.idl";
import "ocidl.idl";
import "atliface.idl";
[
uuid(BEF3BF76-7703-4FCD-9E61-9E9133FA07B3),
version(1.0),
helpstring("StupiderIDL 1.0 Type Library")
]
library StupiderIDLLib
{
importlib("stdole2.tlb");
importlib("..\StupidIDL\Windows Mobile 5.0 Pocket PC SDK (ARMV4I)\Debug
\StupidIDL.tlb");
[
object,
dual,
uuid(BA5B38EA-54D8-49c3-B92B-1EF905DBE780)
]
interface IDerivedInterface : IBaseInterface
{
}
};
====================================================================
This ALONE is enough to get the warning. But, when I add the next IDL, the
compiler crashes when compiling!!
====================================================================
import "oaidl.idl";
import "ocidl.idl";
[
uuid(FFB3EE4E-860B-44d3-BAA6-5CEE134BE007),
version(1.0),
helpstring("StupidestIDL 1.0 Type Library")
]
library StupidestIDLLib
{
importlib("stdole2.tlb");
import "StupiderIDL.IDL";
[
uuid(E9F429D9-584A-489e-95AD-F8E865F7B21A)
]
coclass StupidCoClass
{
[default] interface IDerivedInterface;
};
};
====================================================================
I hope this well help! Thanks in advance... mainly, I just want to know if
what I want to do is possible, and if so, what I might be doing wrong.
David