class CPortScanDlg : public CDialog
{
DECLARE_DYNAMIC(CPortScanDlg)
public:
CPortScanDlg(CWnd* pParent = NULL); // 标准构造函数
virtual ~CPortScanDlg();
// 对话框数据
enum { IDD = IDD_PORTSCAN_DLG };
protected:
//Adds a new item to m_cResult
AddItem( int nItem,int nSubItem,LPCTSTR strItem,int nImageIndex = -1);// 错误位置 error C4430: 缺少类型说明符 - 假定为 int。注意: C++ 不支持默认 int
BOOL TestConnection(CString IP, UINT nPort);
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
afx_msg void OnBnClickedStart();
afx_msg void OnBnClickedStop();
afx_msg void OnBnClickedRadioone();
afx_msg void OnBnClickedRadiomany();
DECLARE_MESSAGE_MAP()
public:
CPtrList* m_pStatusList;//Our link list. The nodes are in type DATA*. See the above structure
CIPAddressCtrl m_ctrlIPAddr;
CEdit m_ctrlOne;
CEdit m_ctrlFrom;
CEdit m_ctrlTo;
CEdit m_ctrlTime;
CListCtrl m_ctrlListResult;
CProgressCtrl m_ctrlProgress;
bool m_nPortOne;
UINT m_minPort,m_maxPort; //Lower bound and upper bound of scanning ports range
UINT m_nCounter;
//Maximum attempts to connect a socket
UINT m_nMaxAttempts;
virtual BOOL OnInitDialog();
CButton m_ctrlBtnStart;
CButton m_ctrlBtnStop;
CStatic m_ctrlStatus;
};
请问各位怎么解决这问题呀?
------解决方案--------------------------------------------------------
找到出事的语句,看看变量的类型是不是有问题...
------解决方案--------------------------------------------------------
AddItem这个函数没有返回值,要显示声明返回值
比如 int AddItem(...)
------解决方案--------------------------------------------------------
AddItem( int nItem,int nSubItem,LPCTSTR strItem,int nImageIndex = -1);// 错误位
????????
返回类型
------解决方案--------------------------------------------------------
1>e:\specture projects code\second try 090629\withexcel\withexcel\debug\excel.tlh(1463) : error C2371: “FontPtr”: 重定义;不同的基类型
1> c:\program files\microsoft visual studio 8\vc\include\comdef.h(312) : 参见“FontPtr”的声明
1>e:\specture projects code\second try 090629\withexcel\withexcel\debug\excel.tlh(1541) : error C2786: “BOOL (__stdcall *)(HDC,int,int,int,int)”: __uuidof 的操作数无效
1>e:\specture projects code\second try 090629\withexcel\withexcel\debug\excel.tlh(1541) : error C2923: “_com_IIID”:“Rectangle”不是参数“_Interface”的有效 模板 类型变量
1> c:\program files\microsoft visual studio 8\vc\platformsdk\include\wingdi.h(3514) : 参见“Rectangle”的声明
1>e:\specture projects code\second try 090629\withexcel\withexcel\debug\excel.tlh(1541) : error C3203: “_com_IIID”: 未专用化的类 模板 不能用作 模板 变量,该变量属于 模板 参数“_IIID”,应为 real 类型
1>e:\specture projects code\second try 090629\withexcel\withexcel\debug\excel.tlh(1545) : error C2786: “BOOL (__stdcall *)(HDC,int,int,int,int,int,int,int,int)”: __uuidof 的操作数无效