线程的创建方法
线程体(也称线程函数)的一般形式:
DWORD WINAPI ThreadProc(LPVOID pParam)
{
return 0;
}
//创建时:
HANDLE hReceiveThread = NULL;
UINT ThreadID;
hReceiveThread = CreateThread(NULL,0,ThreadProc,hWnd,0, &ThreadID);
if ( hReceiveThread == NULL )
return FALSE;
// 优先级等级为普通
SetThreadPriority(hReceiveThread,THREAD_PRIORITY_NORMAL);
本文地址:http://com.8s8s.com/it/it24712.htm