I tried to use the following:
UINT XX::YY(LPVOID pParam)
UINT TestThread(LPVOID pParam)
...
CWinThread *pThread=::AfxBeginThread(XX::YY, GetSafeHwnd(),THREAD_PRIORITY_NORMAL);
CWinThread *test=AfxBeginThread(TestThread,GetSafeHwnd(),THREAD_PRIORITY_NORMAL);
the second version starts, the first is not to be compiled, errormessage is
error C2665: 'AfxBeginThread' : Durch keine der 2 Ueberladungen kann Parameter 1 vom Typ 'unsigned int (void *)' konvertiert werden
(can not find matches between 'unsigned int (void *)' and the function 'AfxBeginThread'
I tried to cast explicit, but the result was the same.
Is it possible to declare and implement a object method as a thread?
Thanx
UINT XX::YY(LPVOID pParam)
UINT TestThread(LPVOID pParam)
...
CWinThread *pThread=::AfxBeginThread(XX::YY, GetSafeHwnd(),THREAD_PRIORITY_NORMAL);
CWinThread *test=AfxBeginThread(TestThread,GetSafeHwnd(),THREAD_PRIORITY_NORMAL);
the second version starts, the first is not to be compiled, errormessage is
error C2665: 'AfxBeginThread' : Durch keine der 2 Ueberladungen kann Parameter 1 vom Typ 'unsigned int (void *)' konvertiert werden
(can not find matches between 'unsigned int (void *)' and the function 'AfxBeginThread'
I tried to cast explicit, but the result was the same.
Is it possible to declare and implement a object method as a thread?
Thanx