⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dlgnewcard.h

📁 VC实现基于串口通讯的食堂饭卡系统,需要和相应的硬件结合实现.废话不多说了,大家下载吧,呵呵,给点评价哦!
💻 H
字号:
//{{AFX_INCLUDES()
#include "mscomm.h"
//}}AFX_INCLUDES
#if !defined(AFX_DLGNEWCARD_H__F6C07E97_9508_4EE6_A1EE_93954A6811F2__INCLUDED_)
#define AFX_DLGNEWCARD_H__F6C07E97_9508_4EE6_A1EE_93954A6811F2__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// DlgNewCard.h : header file
//

#include "CardUser.h"
#include "Card.h"

/////////////////////////////////////////////////////////////////////////////
// CDlgNewCard dialog

class CDlgNewCard : public CDialog
{
// Construction
public:
	void ConfigButtons();
	CDlgNewCard(CWnd* pParent = NULL);   // standard constructor

// Dialog Data
	//{{AFX_DATA(CDlgNewCard)
	enum { IDD = IDD_DIALOG_NEWCARD };
	CButton	m_btnNewCard;
	CListCtrl	m_ListBox;
	float	m_Money;
	CString	m_StudentId;
	CMSComm	m_ComPort;
	//}}AFX_DATA


// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CDlgNewCard)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:
	CCardUser m_CardUser ;
	CCard m_Card;
	CCard m_CardLookupMaxId;

	void InitListView();
	void FillListView();
	void DecodeInt(int A,BYTE& B1, BYTE& B2 );
	bool IsCardInWriter();
    short int WriteCard(CString ACardNo);
    short int WriteTime(CTime ATime);
    short int WriteMoney(float AMoney);
    CString GetNewCardId();

	// Generated message map functions
	//{{AFX_MSG(CDlgNewCard)
	afx_msg void OnClose();
	afx_msg void OnShowWindow(BOOL bShow, UINT nStatus);
	afx_msg void OnButtonQuery();
	afx_msg void OnClickList1(NMHDR* pNMHDR, LRESULT* pResult);
	afx_msg void OnButtonNewCard();
	afx_msg void OnDestroy();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
private:
	CString _IntToStr5(int AInt);
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_DLGNEWCARD_H__F6C07E97_9508_4EE6_A1EE_93954A6811F2__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -