I do not understand what is the difference between using
or instead usingCode:CWinThread* AfxBeginThread( AFX_THREADPROC pfnThreadProc, LPVOID pParam, int nPriority = THREAD_PRIORITY_NORMAL, UINT nStackSize = 0, DWORD dwCreateFlags = 0, LPSECURITY_ATTRIBUTES lpSecurityAttrs = NULL ); CWinThread* AfxBeginThread( CRuntimeClass* pThreadClass, int nPriority = THREAD_PRIORITY_NORMAL, UINT nStackSize = 0, DWORD dwCreateFlags = 0, LPSECURITY_ATTRIBUTES lpSecurityAttrs = NULL );
in Windows XP or Windows CECode:HANDLE WINAPI CreateThread( __in_opt LPSECURITY_ATTRIBUTES lpThreadAttributes, __in SIZE_T dwStackSize, __in LPTHREAD_START_ROUTINE lpStartAddress, __in_opt LPVOID lpParameter, __in DWORD dwCreationFlags, __out_opt LPDWORD lpThreadId );
What is the difference in practice (except for the first using an object and the second only an handle)? Are they compliant one another may be the first an enhacement of the second??
Are they both used together with the same following function to test thread exit?
Thank youCode:BOOL WINAPI GetExitCodeThread( __in HANDLE hThread, __out LPDWORD lpExitCode );



LinkBack URL
About LinkBacks



