views:

104

answers:

1

I'm trying to use midl to turn an idl file into a tlb. However, when I try I get this warning:

warning MIDL2015: failed to load tlb in importlib : mscorlib.tlb

and I then get a subsequent error:

error MIDL2337 : unsatisfied forward declaration : _Object.....

I'm certain that the error is due to the first warning. I've tried the same command on a different machine and it succeeds, so I know that the idl file is correct.

I've tried uninstalling the .NET framework and reinstalling it in the hope that that would fix things, but it had no effect.

So my question is, what do I need to fix on my machine to allow midl to locate mscorlib.tlb once more?

A: 

Turned out to be a problem with my PATH env variable - it didn't include C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\, but this was specified on the other machine.

Akash