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

📄 frmuser.cs

📁 实现ATM模拟
💻 CS
📖 第 1 页 / 共 5 页
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.Net;
using System.Net.Sockets;
using System.IO;
using System.Threading;
using System.Drawing.Printing;



namespace Client
{
	/// <summary>
	/// Form1 的摘要说明。
	/// </summary>
	public class frmMain : System.Windows.Forms.Form
	{
		public string message="";
		private System.Windows.Forms.TabControl tabControl1;
		private System.Windows.Forms.TabPage tabPage1;
		private System.Windows.Forms.TabPage tabPage2;
		private System.Windows.Forms.TabPage tabPage3;
		private System.Windows.Forms.TabPage tabPage4;
		private System.Windows.Forms.TabPage tabPage5;
		private System.Windows.Forms.TabPage tabPage6;
		private System.Windows.Forms.TabPage tabPage7;
		private System.Windows.Forms.TabPage tabPage8;
		private System.Windows.Forms.GroupBox groupBox1;
		private System.Windows.Forms.Button btn110;
		private System.Windows.Forms.Button btnCunKuan;
		private System.Windows.Forms.Button btnQuKuan;
		private System.Windows.Forms.Button btnzhuanzhang;
		private System.Windows.Forms.Button btnSelect;
		private System.Windows.Forms.TextBox txtPwd;
		private System.Windows.Forms.Label lblPwd;
		private System.Windows.Forms.Label lblId;
		private System.Windows.Forms.TextBox txtID;
		private System.Windows.Forms.Button btnQueDing1;
		private System.Windows.Forms.Button btnSelectZH;
		private System.Windows.Forms.Button btnNew;
		private System.Windows.Forms.Button btnQueDing3;
		private System.Windows.Forms.TextBox txtZhuanMoney;
		private System.Windows.Forms.TextBox txtDuiZhang;
		private System.Windows.Forms.Label lblZhuanMoney;
		private System.Windows.Forms.Label lblDuiZhang;
		private System.Windows.Forms.TextBox txtADuiZhang;
		private System.Windows.Forms.Label lblADuiZhang;
		private System.Windows.Forms.Button btnChongZhi;
		private System.Windows.Forms.Button btnQueDing4;
		private System.Windows.Forms.TextBox txtQueQian;
		private System.Windows.Forms.Label lblQuQian;
		private System.Windows.Forms.TextBox txtChunQian;
		private System.Windows.Forms.Label lblCunQian;
		private System.Windows.Forms.Button btnChongZhi5;
		private System.Windows.Forms.Button btnQueDing5;
		private System.Windows.Forms.Button btnTuiKa;
		private System.Windows.Forms.Button btnFanHui;
		private System.Windows.Forms.Label lblErrorMsg;
		private System.Windows.Forms.Label lblOkMsg;
		private System.Windows.Forms.Button btnNum0;
		private System.Windows.Forms.Button btnNum9;
		private System.Windows.Forms.Button btnNum8;
		private System.Windows.Forms.Button btnNum7;
		private System.Windows.Forms.Button btnNum6;
		private System.Windows.Forms.Button btnNum5;
		private System.Windows.Forms.Button btnNum4;
		private System.Windows.Forms.Button btnNum3;
		private System.Windows.Forms.Button btnNum2;
		private System.Windows.Forms.Button btnNum1;
		private System.Windows.Forms.Button button1;
		private System.Windows.Forms.Button btnBackY;
		private System.Windows.Forms.Button btnPrint;
		private System.Windows.Forms.Timer timer1;
		private System.ComponentModel.IContainer components;
		private System.Windows.Forms.Timer timer2;
		private System.Windows.Forms.PictureBox pictureBox1;
		private System.Windows.Forms.Timer timer3;
		private System.Windows.Forms.Label lblYanZheng;
		private System.Windows.Forms.Button button2;
		private System.Windows.Forms.Button button3;
		private System.Windows.Forms.Button btnBackQu;
		private System.Windows.Forms.Button btnBackCun;
		private System.Windows.Forms.PrintPreviewDialog printPreviewDialog1;
		private System.Drawing.Printing.PrintDocument printDocument1;
		private System.Windows.Forms.TabPage tabPage9;
		//private System.ComponentModel.IContainer components;

		public frmMain()
		{
			//
			// Windows 窗体设计器支持所必需的
			//
			InitializeComponent();

			//
			// TODO: 在 InitializeComponent 调用后添加任何构造函数代码
			//
		}

		/// <summary>
		/// 清理所有正在使用的资源。
		/// </summary>
		protected override void Dispose( bool disposing )
		{
			if( disposing )
			{
//				if (components != null) 
//				{
//					components.Dispose();
//				}
			}
			base.Dispose( disposing );
		}

		#region Windows 窗体设计器生成的代码
		/// <summary>
		/// 设计器支持所需的方法 - 不要使用代码编辑器修改
		/// 此方法的内容。
		/// </summary>
		private void InitializeComponent()
		{
			this.components = new System.ComponentModel.Container();
			System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(frmMain));
			this.tabControl1 = new System.Windows.Forms.TabControl();
			this.tabPage1 = new System.Windows.Forms.TabPage();
			this.btn110 = new System.Windows.Forms.Button();
			this.btnCunKuan = new System.Windows.Forms.Button();
			this.btnQuKuan = new System.Windows.Forms.Button();
			this.btnzhuanzhang = new System.Windows.Forms.Button();
			this.btnSelect = new System.Windows.Forms.Button();
			this.tabPage2 = new System.Windows.Forms.TabPage();
			this.btnChongZhi = new System.Windows.Forms.Button();
			this.btnQueDing1 = new System.Windows.Forms.Button();
			this.txtPwd = new System.Windows.Forms.TextBox();
			this.lblPwd = new System.Windows.Forms.Label();
			this.lblId = new System.Windows.Forms.Label();
			this.txtID = new System.Windows.Forms.TextBox();
			this.tabPage4 = new System.Windows.Forms.TabPage();
			this.button1 = new System.Windows.Forms.Button();
			this.btnQueDing4 = new System.Windows.Forms.Button();
			this.txtQueQian = new System.Windows.Forms.TextBox();
			this.lblQuQian = new System.Windows.Forms.Label();
			this.tabPage3 = new System.Windows.Forms.TabPage();
			this.btnSelectZH = new System.Windows.Forms.Button();
			this.tabPage5 = new System.Windows.Forms.TabPage();
			this.btnChongZhi5 = new System.Windows.Forms.Button();
			this.btnQueDing5 = new System.Windows.Forms.Button();
			this.txtChunQian = new System.Windows.Forms.TextBox();
			this.lblCunQian = new System.Windows.Forms.Label();
			this.tabPage6 = new System.Windows.Forms.TabPage();
			this.txtADuiZhang = new System.Windows.Forms.TextBox();
			this.lblADuiZhang = new System.Windows.Forms.Label();
			this.btnNew = new System.Windows.Forms.Button();
			this.btnQueDing3 = new System.Windows.Forms.Button();
			this.txtZhuanMoney = new System.Windows.Forms.TextBox();
			this.txtDuiZhang = new System.Windows.Forms.TextBox();
			this.lblZhuanMoney = new System.Windows.Forms.Label();
			this.lblDuiZhang = new System.Windows.Forms.Label();
			this.tabPage8 = new System.Windows.Forms.TabPage();
			this.lblErrorMsg = new System.Windows.Forms.Label();
			this.tabPage7 = new System.Windows.Forms.TabPage();
			this.btnPrint = new System.Windows.Forms.Button();
			this.btnTuiKa = new System.Windows.Forms.Button();
			this.btnFanHui = new System.Windows.Forms.Button();
			this.lblOkMsg = new System.Windows.Forms.Label();
			this.tabPage9 = new System.Windows.Forms.TabPage();
			this.groupBox1 = new System.Windows.Forms.GroupBox();
			this.btnNum0 = new System.Windows.Forms.Button();
			this.btnNum9 = new System.Windows.Forms.Button();
			this.btnNum8 = new System.Windows.Forms.Button();
			this.btnNum7 = new System.Windows.Forms.Button();
			this.btnNum6 = new System.Windows.Forms.Button();
			this.btnNum5 = new System.Windows.Forms.Button();
			this.btnNum4 = new System.Windows.Forms.Button();
			this.btnNum3 = new System.Windows.Forms.Button();
			this.btnNum2 = new System.Windows.Forms.Button();
			this.btnNum1 = new System.Windows.Forms.Button();
			this.btnBackY = new System.Windows.Forms.Button();
			this.timer1 = new System.Windows.Forms.Timer(this.components);
			this.timer2 = new System.Windows.Forms.Timer(this.components);
			this.pictureBox1 = new System.Windows.Forms.PictureBox();
			this.lblYanZheng = new System.Windows.Forms.Label();
			this.timer3 = new System.Windows.Forms.Timer(this.components);
			this.button2 = new System.Windows.Forms.Button();
			this.button3 = new System.Windows.Forms.Button();
			this.btnBackQu = new System.Windows.Forms.Button();
			this.btnBackCun = new System.Windows.Forms.Button();
			this.printPreviewDialog1 = new System.Windows.Forms.PrintPreviewDialog();
			this.printDocument1 = new System.Drawing.Printing.PrintDocument();
			this.tabControl1.SuspendLayout();
			this.tabPage1.SuspendLayout();
			this.tabPage2.SuspendLayout();
			this.tabPage4.SuspendLayout();
			this.tabPage3.SuspendLayout();
			this.tabPage5.SuspendLayout();
			this.tabPage6.SuspendLayout();
			this.tabPage8.SuspendLayout();
			this.tabPage7.SuspendLayout();
			this.tabPage9.SuspendLayout();
			this.groupBox1.SuspendLayout();
			this.SuspendLayout();
			// 
			// tabControl1
			// 
			this.tabControl1.Controls.Add(this.tabPage1);
			this.tabControl1.Controls.Add(this.tabPage2);
			this.tabControl1.Controls.Add(this.tabPage3);
			this.tabControl1.Controls.Add(this.tabPage4);
			this.tabControl1.Controls.Add(this.tabPage5);
			this.tabControl1.Controls.Add(this.tabPage6);
			this.tabControl1.Controls.Add(this.tabPage7);
			this.tabControl1.Controls.Add(this.tabPage8);
			this.tabControl1.Controls.Add(this.tabPage9);
			this.tabControl1.Location = new System.Drawing.Point(-8, -24);
			this.tabControl1.Name = "tabControl1";
			this.tabControl1.SelectedIndex = 0;
			this.tabControl1.Size = new System.Drawing.Size(616, 480);
			this.tabControl1.TabIndex = 0;
			// 
			// tabPage1
			// 
			this.tabPage1.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("tabPage1.BackgroundImage")));
			this.tabPage1.Controls.Add(this.btn110);
			this.tabPage1.Controls.Add(this.btnCunKuan);
			this.tabPage1.Controls.Add(this.btnQuKuan);
			this.tabPage1.Controls.Add(this.btnzhuanzhang);
			this.tabPage1.Controls.Add(this.btnSelect);
			this.tabPage1.Location = new System.Drawing.Point(4, 21);
			this.tabPage1.Name = "tabPage1";
			this.tabPage1.Size = new System.Drawing.Size(608, 455);
			this.tabPage1.TabIndex = 0;
			this.tabPage1.Text = "主页面";
			this.tabPage1.Click += new System.EventHandler(this.tabPage1_Click);
			// 
			// btn110
			// 
			this.btn110.BackColor = System.Drawing.Color.Transparent;
			this.btn110.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.btn110.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.btn110.Location = new System.Drawing.Point(8, 264);
			this.btn110.Name = "btn110";
			this.btn110.Size = new System.Drawing.Size(96, 40);
			this.btn110.TabIndex = 5;
			this.btn110.Text = "报警";
			this.btn110.Click += new System.EventHandler(this.button23_Click);
			// 
			// btnCunKuan
			// 
			this.btnCunKuan.BackColor = System.Drawing.Color.Transparent;
			this.btnCunKuan.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.btnCunKuan.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.btnCunKuan.Location = new System.Drawing.Point(504, 180);
			this.btnCunKuan.Name = "btnCunKuan";
			this.btnCunKuan.Size = new System.Drawing.Size(96, 40);
			this.btnCunKuan.TabIndex = 4;
			this.btnCunKuan.Text = "存款";
			this.btnCunKuan.Click += new System.EventHandler(this.button22_Click);
			// 
			// btnQuKuan
			// 
			this.btnQuKuan.BackColor = System.Drawing.Color.Transparent;
			this.btnQuKuan.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.btnQuKuan.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.btnQuKuan.Location = new System.Drawing.Point(504, 96);
			this.btnQuKuan.Name = "btnQuKuan";
			this.btnQuKuan.Size = new System.Drawing.Size(96, 40);
			this.btnQuKuan.TabIndex = 3;
			this.btnQuKuan.Text = "取款";
			this.btnQuKuan.Click += new System.EventHandler(this.button21_Click);
			// 
			// btnzhuanzhang
			// 
			this.btnzhuanzhang.BackColor = System.Drawing.Color.Transparent;
			this.btnzhuanzhang.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.btnzhuanzhang.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.btnzhuanzhang.Location = new System.Drawing.Point(8, 180);
			this.btnzhuanzhang.Name = "btnzhuanzhang";
			this.btnzhuanzhang.Size = new System.Drawing.Size(96, 40);
			this.btnzhuanzhang.TabIndex = 2;
			this.btnzhuanzhang.Text = "转帐";
			this.btnzhuanzhang.Click += new System.EventHandler(this.button20_Click);
			// 
			// btnSelect
			// 
			this.btnSelect.BackColor = System.Drawing.Color.Transparent;
			this.btnSelect.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.btnSelect.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.btnSelect.Location = new System.Drawing.Point(8, 96);
			this.btnSelect.Name = "btnSelect";
			this.btnSelect.Size = new System.Drawing.Size(96, 40);
			this.btnSelect.TabIndex = 1;
			this.btnSelect.Text = "余额查询";
			this.btnSelect.Click += new System.EventHandler(this.button19_Click);
			// 
			// tabPage2
			// 
			this.tabPage2.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("tabPage2.BackgroundImage")));
			this.tabPage2.Controls.Add(this.btnChongZhi);
			this.tabPage2.Controls.Add(this.btnQueDing1);
			this.tabPage2.Controls.Add(this.txtPwd);
			this.tabPage2.Controls.Add(this.lblPwd);
			this.tabPage2.Controls.Add(this.lblId);
			this.tabPage2.Controls.Add(this.txtID);
			this.tabPage2.Location = new System.Drawing.Point(4, 21);
			this.tabPage2.Name = "tabPage2";
			this.tabPage2.Size = new System.Drawing.Size(608, 455);
			this.tabPage2.TabIndex = 1;
			this.tabPage2.Text = "登陆";
			this.tabPage2.Click += new System.EventHandler(this.tabPage2_Click);
			// 
			// btnChongZhi
			// 
			this.btnChongZhi.BackColor = System.Drawing.Color.Transparent;
			this.btnChongZhi.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.btnChongZhi.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.btnChongZhi.Location = new System.Drawing.Point(504, 96);
			this.btnChongZhi.Name = "btnChongZhi";
			this.btnChongZhi.Size = new System.Drawing.Size(96, 40);
			this.btnChongZhi.TabIndex = 8;
			this.btnChongZhi.Text = "重置";
			this.btnChongZhi.Click += new System.EventHandler(this.btnChongZhi_Click);
			// 
			// btnQueDing1
			// 
			this.btnQueDing1.BackColor = System.Drawing.Color.Transparent;
			this.btnQueDing1.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.btnQueDing1.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.btnQueDing1.Location = new System.Drawing.Point(8, 96);
			this.btnQueDing1.Name = "btnQueDing1";
			this.btnQueDing1.Size = new System.Drawing.Size(96, 40);
			this.btnQueDing1.TabIndex = 4;
			this.btnQueDing1.Text = "确定";
			this.btnQueDing1.Click += new System.EventHandler(this.button2_Click);
			// 
			// txtPwd
			// 
			this.txtPwd.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
			this.txtPwd.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.txtPwd.Location = new System.Drawing.Point(240, 224);
			this.txtPwd.Multiline = true;
			this.txtPwd.Name = "txtPwd";
			this.txtPwd.PasswordChar = '*';
			this.txtPwd.Size = new System.Drawing.Size(224, 28);
			this.txtPwd.TabIndex = 3;
			this.txtPwd.Text = "";
			// 
			// lblPwd

⌨️ 快捷键说明

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