PREVIOUS ClientDlg.cpp is the class where all the action from user's are taken and initiated. The interaction with GUI to logic is so great and easy which will help any developer to understand the flow of code. Function for login -- void CClientDlg::OnBnClickedButton2() { // TODO: Add your control notification handler code here cTh = AfxBeginThread( StaticThreadFunc, this); m_Thread_handle = cTh->m_hThread; } Start the thread for a login action. UINT __cdecl CClientDlg::StaticThreadFunc(LPVOID pParam) { CClientDlg *pYourClass = reinterpret_cast<CClientDlg*>(pParam); UINT retCode = pYourClass->ThreadFunc(); return retCode; } UINT CClientDlg::ThreadFunc() { // Do your thing, this thread now has access to all the classes member variables ...
Network programming and scalable micro-services in Azure