新微赢技术网

标题: 新手求助:error C1004: unexpected end of file found [打印本页]

作者: 木子    时间: 2009-11-3 03:43
标题: 新手求助:error C1004: unexpected end of file found
貌似也沒有語法錯誤,怎麼會有這樣的問題?請各位高手幫忙!

出錯提示如下:
e:\study\qq\qq.cpp(7) : error C2146: syntax error : missing ';' before identifier 'bb'
e:\study\qq\qq.cpp(7) : fatal error C1004: unexpected end of file found
代碼如下:
extern CString bb;
void CAboutDlg::OnKillFocus(CWnd* pNewWnd)
{
 // TODO: Add your message handler code here
 CDialog::OnKillFocus(pNewWnd);
 bb=m_edit;
}
//對于OICQVIEW類
char aa[100];
CString mm;
CDC* pdc;
class mysock:public CSocket //派生mysock類,此類既有接受功能
{public:void OnReceive(int nErrorCode) //可以隨時接收信息
 {
  CSocket::Receive((void*)aa,100,0);
     mm=aa;
  CString ll=" ";    //在顯示消息之前,消除前面發送的消息
  pdc->TextOut(50,50,ll);
  pdc->TextOut(50,50,mm);
 }
};

mysock sock1;
CString bb;
BOOL COicqView::OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message)
{
 CView::OnSetFocus(pOldWnd);
 // TODO: Add your message handler code here and/or call default
 bb="besting:"+bb; //确定發送者身份為besting
 sock1.SendTo(bb,100,1060,"192.168.0.255",0); //獲得焦點以廣播形式發送信息,端口號為1060
 return CView::OnSetCursor(pWnd, nHitTest, message);
}

int COicqView::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
 if (CView::OnCreate(lpCreateStruct) == -1)
  




欢迎光临 新微赢技术网 (http://bbs.weiying.cn/) Powered by Discuz! X3.2