摘要:
在InitInstance里面添加:HRESULT CoInitializeEx( void * pvReserved, //must be null currently DWORD dwCoInit //see the following definition to COINIT);typedef enum tagCOINIT { COINIT_MULTITHREADED = 0x0, COINIT_APARTMENTTHREADED = 0x2, COINIT_DISABLE_OLE1DDE = 0x4, COIN... 阅读全文
摘要:
有如下继承关系的几个类:以下是类的相关代码://抽象基类:动物类class CAnimal{public: virtual void EatFood(string strSomething) = 0; virtual void Drink(string strSomething) = 0;};//CAnimal的派生类:CMammalclass CMammal : public CAnimal{public: virtual void EatFood(string strSomething) { cout << "CMammal::EatFood()" ... 阅读全文