Tag «threads»

How to create thread from class’s method

Sometimes I need start thread from class method. Compiler return error while compilation. error C2664: ‘CreateThread’ : cannot convert parameter 3 from ‘unsigned long (__thiscall CMyClass::*)(void *)’ to ‘unsigned long (__stdcall *)(void *)’ Compiler is right. Static function address is needed to CreateThread. But If you start class method you want it should act as …