The general form of a thread body thread creation method (also called a thread function): DWORD WINAPI ThreadProc (LPVOID pParam) {return 0;} // Create time: HANDLE hReceiveThread = NULL; UINT ThreadID; hReceiveThread = CreateThread (NULL, 0, ThreadProc , hwnd, 0, & threadid; if (hreceivethread == null) return false; // Priority level is normal setthreadPriority (HRECEIVETHREAD, Thread_Priority_Normal);