2009년 12월 28일 월요일

CSocket -> Dialog 메시지

다이얼로그 유저 메시지 추가

헤더 각각 추가

class <class name> 추가

생성자 수정

생성자(class * pDlg)
{
  m_pDlg = pDlg;
}

m_pDlg->PostMessage(WM_USER_MSG,0,0)  호출

Socket Create 실패


socket create() 함수에서 에러 발생

초기화를 하지 않아서

sockcore.cpp 에서 에러가 발생한다.

if (pState->m_pmapSocketHandle->IsEmpty())

InitInstance() 함수에서 다음을 추가한다.

    if (!AfxSocketInit())
    {
        AfxMessageBox(_T("Socket Init Fail"));
        return FALSE;
    }