Hi > > I can't find CLSCTX_ALL in MSDN. Have you tried calling CoCreateInstance > > directly using > > CLSCTX_LOCAL_SERVER to see if that works? > > (CLSCTX_ALL = CLSCTX_SERVER + some other one I can't remember) > > Yes - I first tried the long method starting with CLSIDFromProg() and going > through to QueryInterface() on the class factory to get my own interface. > > CoCreateInstance() (with LOCAL_SERVER) succeeded for the class factory, but > not directly for IFoo - it came back E_NOINTERFACE. Similarly, if I tried > QueryInterface() from the class factory that also said E_NOINTERFACE. No > idea why since IFoo is there!
Ok, I'm not entirely sure i follow (again, it's a long time (read years) since I've done any automation). Have you tried this: IFoo* pIFoo = 0; HRESULT hr = CoCreateInstance( CLSID_IFOO, 0, CLSID_LOCAL_SERVER, IID_IFOO, &pIFoo ); All the paramters might not quite be correct as I'm going from memory and you may need a reinterperet_cast in there at the end. > Why are these things so <censored> complicated??? because, as usual, Microsoft thought they could do better than an already well established distributed object system (CORBA), when clearly they can't. This is what happens when you drive software development with marketing rather than the ideal of making good software. Regards Paul Paul Grenyer Email: [EMAIL PROTECTED] Web: http://www.paulgrenyer.co.uk Have you met Aeryn: http://www.paulgrenyer.co.uk/aeryn/? Version 0.3.0 beta now ready for download
