// H7 ServerDlg.h : header file // #pragma once #include "afxwin.h" #include "TcpServerClass.h" #include "H7Serial.h" //forward declaration class TcpClientClass; #include // Fortæller at der er en funktion, et eller andet sted, der hedder GetAvailableComPorts(). std::vector GetAvailableComPorts(); // CH7ServerDlg dialog class CH7ServerDlg : public CDialog { // Construction public: CH7ServerDlg(CWnd* pParent = NULL); // standard constructor // Dialog Data enum { IDD = IDD_H7SERVER_DIALOG }; protected: virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support // Implementation protected: HICON m_hIcon; TcpServerClass TcpServer; // Generated message map functions virtual BOOL OnInitDialog(); afx_msg void OnSysCommand(UINT nID, LPARAM lParam); afx_msg void OnPaint(); afx_msg HCURSOR OnQueryDragIcon(); DECLARE_MESSAGE_MAP() public: bool m_First; CEdit m_Status; CComboBox m_BaudRate; CComboBox m_Serial; CButton m_Stop; CEdit m_Port; int m_Start; CH7Serial H7Serial; CButton m_Restart; int StartTcp(void); bool ServerInit(void); int StartSerial(void); void NewLine(void); CString OnOff(int value); void UpdateStatus(CString name, short value); void UpdateClient(TcpClientClass *caller); afx_msg void OnBnClickedStart(); afx_msg void OnBnClickedTest(); afx_msg void OnBnClickedRestart(); afx_msg void OnBnClickedStop(); void TcpStatus(void); CButton m_StartB; protected: virtual void OnCancel(); };