views:

29

answers:

1

Getting this error on a call inside the Delphi Initialization section of an Impl unit on a line like.

TAutoObjectFactory.Create(ComServer, TmyClass, Class_myclass, ciMultiInstance, tmApartment);

the type is defined as

  Tmyclass = class(TAutoObject, IConnectionPointContainer, Imyclass)

and it results ultimately in a "Runtime error 217 at .... " running it outisde the debugger.

This class is defined in 1 project and works fine. It's blowing up with this error in another project that uses it and it's dependent upon.

Can anyone tell me what to look for? This is code that's been in production for a while but no one's machine was setup to compile it since 01/2009 and I'm doing it the first time in Delphi 7, was Delphi 6 before.

Thanks David

A: 

Never mind. I used the Iclass instead of the TClass in my code to get around this.

Thanks.

DavieDave