首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > .NET > .NET >

error C2059

2014-01-28 
从来没搞过C++,遇到问题向各位请教 一段VC++ 6下的代码,我用vs2005打开后编译提示出错error C2059等:源代码

从来没搞过C++,遇到问题向各位请教
一段VC++ 6下的代码,我用vs2005打开后编译提示出错error C2059等:源代码如下


// EasyNetView.h : interface of the CEasyNetView class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_EasyNetVIEW_H__0FAEEE9E_09DD_465E_84D0_83B228A2D11A__INCLUDED_)
#define AFX_EasyNetVIEW_H__0FAEEE9E_09DD_465E_84D0_83B228A2D11A__INCLUDED_

#include <afxmt.h>

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#define MAXClient 60


const int WINSOCK_VERSION = 0x0101;
const int DEFAULT_PROTOCOL  = 0;
const int NO_FLAGS = 0; // No special flags specified
const int MAX_COLUMNS = 80; // Maximum columns for text display
const int QUEUE_SIZE = 5;

const int WM_SERVER_ACCEPT = WM_USER+101;
const int WM_CLIENT_CLOSE = WM_USER+102;
const int WM_CLIENT_READ = WM_USER+103;
const int WM_CLIENT_READCLOSE=WM_USER+105;

class CEasyNetDoc;
extern long g_AutoSendConnectID;
extern BOOL g_StopShow;

class CEasyNetView : public CFormView
{
protected: // create from serialization only
CEasyNetView();
DECLARE_DYNCREATE(CEasyNetView)

public:
//{{AFX_DATA(CEasyNetView)
enum { IDD = IDD_EasyNet_FORM };
CListCtrl m_ListInfo;
CEdit m_RXCOUNT;
CEdit m_edtTxData;
CEdit m_edtRxData;
CEdit m_edtTimer;
CButton m_btnSend;
UINT m_rxCount;
CString m_rxData;
UINT m_timer;
CString m_txData;
BOOL m_bAutoSend;
UINT m_txCount;
CString m_FilePath;
long m_ConnectID;
//}}AFX_DATA

// Attributes
public:
CEasyNetDoc* GetDocument();

virtual void ReportWinsockErr(LPSTR lpszErrorMsg);
int m_bReadType;  //read type
CString m_strfilename;  //file name
CFile m_file; 

// Operations
public:

void CloseConnect(long ConnectID);
void CloseAllConnect();
BOOL Send(long ConnectID);

// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CEasyNetView)
public:
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
protected:
virtual void DoDataExchange(CDataExchange* pDX);  // DDX/DDV support
virtual void OnInitialUpdate(); // called first time after construct
//}}AFX_VIRTUAL

// Implementation
public:
CEvent m_SendEvent;
UINT m_TimerID;
UINT m_nServerPort; // Server socket handle
SOCKET m_hServerSocket; // Server port
SOCKADDR_IN m_sockServerAddr;
DWORD m_nServerip;         

热点排行