views:

188

answers:

1

I have an IDL file with some interfaces in it.

[
   object,
   uuid(newguid),
   dual,
   helpstring("NewInterface Interface"),
   pointer_default(unique)
]
interface INewInterface: IOldInterface
{
   [id(newid), helpstring("method NewMethod")] HRESULT NewMethod([in] BSTR bstrParam );
}

But when I compile my code it does not see my new interface. Also when I open the .tlh file it has not been updated to display the new interface.

Any thoughts on what I need to do?

Edit: Imports are made via

#import "File.tlb" raw_interfaces_only no_namespace

The tlb file does not seem to be getting updated either :(

+1  A: 

The .tlh and .tli file should be updated when the .tlb timestamp has changed and you're #importing it. The .tlb file is the output when compiling the .idl file. So you should check

  • if the compile-settings for the .idl file are correct (configuration-dependent!)
  • if the .tlb imported is really the same as the one compiled (check the include paths), as sharptooth described in the comment.

Beyond that, clearing/deleting all output-files manually sometimes makes a difference. Although, I've to say, the usual problem with the MS toolchain using the project-files is that it is recompiling too often instead not often enough, so beyond configuration problems I've not had such a problem as you describe.

gimpf
The error was solved with a reboot. Thank you for the information though.
Zenox