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

📄 sale.cs

📁 《C#数据库项目案例导航》一书的配套光盘
💻 CS
📖 第 1 页 / 共 2 页
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;

namespace Sale
{
	/// <summary>
	/// Form7 的摘要说明。
	/// </summary>
	public class Sale : System.Windows.Forms.Form
	{		
		private System.Windows.Forms.Button btnApply;
		private System.Windows.Forms.GroupBox groupBox1;
		private System.Windows.Forms.Label label10;
		private System.Windows.Forms.Label label7;
		private System.Windows.Forms.Label label8;
		private System.Windows.Forms.Label label9;
		private System.Windows.Forms.Label label4;
		private System.Windows.Forms.Label label6;
		private System.Windows.Forms.Label lblDatasetPosition;
		private System.Windows.Forms.Button btnLast;
		private System.Windows.Forms.Button btnNext;
		private System.Windows.Forms.Button btnPrevious;
		private System.Windows.Forms.Button btnFirst;
		private System.Windows.Forms.TextBox textProductUnit;
		private System.Windows.Forms.TextBox textProductSpecity;
		private System.Windows.Forms.TextBox textProductName;
		private System.Windows.Forms.TextBox textProductId;
		private System.Windows.Forms.GroupBox groupBox2;
		private System.Windows.Forms.Label label5;
		private System.Windows.Forms.Label label3;
		private System.Windows.Forms.Label label2;
		private System.Windows.Forms.Label label1;
		private System.Windows.Forms.Button btnAdd;
		private System.Windows.Forms.Button btnDelete;
		private System.Windows.Forms.Button btnQuery;
		private System.Windows.Forms.Button btnModify;
		private System.Windows.Forms.Button btnPrint;
		private System.Windows.Forms.Button btnExit;
		private System.Windows.Forms.Button btnCancel;
		private System.Windows.Forms.TextBox textSaleId;
		private System.Windows.Forms.TextBox textSaleDate;
		private System.Windows.Forms.TextBox textSalePrice;
		private System.Windows.Forms.TextBox textSaleAmount;
		private System.Windows.Forms.TextBox textClientName;
		private System.Windows.Forms.TextBox textClientId;
		private System.Windows.Forms.TextBox textSaleRemark;
			
		
		/// <summary>
		/// 必需的设计器变量。
		/// </summary>
		private System.ComponentModel.Container components = null;

		public Sale()
		{
			//
			// 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()
		{
			System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(Sale));
			this.btnApply = new System.Windows.Forms.Button();
			this.groupBox1 = new System.Windows.Forms.GroupBox();
			this.textSaleId = new System.Windows.Forms.TextBox();
			this.label10 = new System.Windows.Forms.Label();
			this.textSaleDate = new System.Windows.Forms.TextBox();
			this.textSalePrice = new System.Windows.Forms.TextBox();
			this.textSaleAmount = new System.Windows.Forms.TextBox();
			this.label7 = new System.Windows.Forms.Label();
			this.label8 = new System.Windows.Forms.Label();
			this.label9 = new System.Windows.Forms.Label();
			this.textClientName = new System.Windows.Forms.TextBox();
			this.textClientId = new System.Windows.Forms.TextBox();
			this.label4 = new System.Windows.Forms.Label();
			this.label6 = new System.Windows.Forms.Label();
			this.lblDatasetPosition = new System.Windows.Forms.Label();
			this.btnLast = new System.Windows.Forms.Button();
			this.btnNext = new System.Windows.Forms.Button();
			this.btnPrevious = new System.Windows.Forms.Button();
			this.btnFirst = new System.Windows.Forms.Button();
			this.textProductUnit = new System.Windows.Forms.TextBox();
			this.textProductSpecity = new System.Windows.Forms.TextBox();
			this.textProductName = new System.Windows.Forms.TextBox();
			this.textProductId = new System.Windows.Forms.TextBox();
			this.groupBox2 = new System.Windows.Forms.GroupBox();
			this.textSaleRemark = new System.Windows.Forms.TextBox();
			this.label5 = new System.Windows.Forms.Label();
			this.label3 = new System.Windows.Forms.Label();
			this.label2 = new System.Windows.Forms.Label();
			this.label1 = new System.Windows.Forms.Label();
			this.btnAdd = new System.Windows.Forms.Button();
			this.btnDelete = new System.Windows.Forms.Button();
			this.btnQuery = new System.Windows.Forms.Button();
			this.btnModify = new System.Windows.Forms.Button();
			this.btnPrint = new System.Windows.Forms.Button();
			this.btnExit = new System.Windows.Forms.Button();
			this.btnCancel = new System.Windows.Forms.Button();
			this.groupBox1.SuspendLayout();
			this.groupBox2.SuspendLayout();
			this.SuspendLayout();
			// 
			// btnApply
			// 
			this.btnApply.Location = new System.Drawing.Point(438, 386);
			this.btnApply.Name = "btnApply";
			this.btnApply.Size = new System.Drawing.Size(72, 24);
			this.btnApply.TabIndex = 47;
			this.btnApply.Text = "应用";
			this.btnApply.Click += new System.EventHandler(this.btnApply_Click);
			// 
			// groupBox1
			// 
			this.groupBox1.Controls.Add(this.textSaleId);
			this.groupBox1.Controls.Add(this.label10);
			this.groupBox1.Controls.Add(this.textSaleDate);
			this.groupBox1.Controls.Add(this.textSalePrice);
			this.groupBox1.Controls.Add(this.textSaleAmount);
			this.groupBox1.Controls.Add(this.label7);
			this.groupBox1.Controls.Add(this.label8);
			this.groupBox1.Controls.Add(this.label9);
			this.groupBox1.Controls.Add(this.textClientName);
			this.groupBox1.Controls.Add(this.textClientId);
			this.groupBox1.Controls.Add(this.label4);
			this.groupBox1.Controls.Add(this.label6);
			this.groupBox1.Controls.Add(this.lblDatasetPosition);
			this.groupBox1.Controls.Add(this.btnLast);
			this.groupBox1.Controls.Add(this.btnNext);
			this.groupBox1.Controls.Add(this.btnPrevious);
			this.groupBox1.Controls.Add(this.btnFirst);
			this.groupBox1.Controls.Add(this.textProductUnit);
			this.groupBox1.Controls.Add(this.textProductSpecity);
			this.groupBox1.Controls.Add(this.textProductName);
			this.groupBox1.Controls.Add(this.textProductId);
			this.groupBox1.Controls.Add(this.groupBox2);
			this.groupBox1.Controls.Add(this.label5);
			this.groupBox1.Controls.Add(this.label3);
			this.groupBox1.Controls.Add(this.label2);
			this.groupBox1.Controls.Add(this.label1);
			this.groupBox1.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.groupBox1.Location = new System.Drawing.Point(10, 18);
			this.groupBox1.Name = "groupBox1";
			this.groupBox1.Size = new System.Drawing.Size(576, 312);
			this.groupBox1.TabIndex = 39;
			this.groupBox1.TabStop = false;
			this.groupBox1.Text = "商品信息";
			// 
			// textSaleId
			// 
			this.textSaleId.Cursor = System.Windows.Forms.Cursors.Arrow;
			this.textSaleId.Location = new System.Drawing.Point(96, 64);
			this.textSaleId.Name = "textSaleId";
			this.textSaleId.Size = new System.Drawing.Size(120, 23);
			this.textSaleId.TabIndex = 37;
			this.textSaleId.Text = "";
			// 
			// label10
			// 
			this.label10.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label10.Location = new System.Drawing.Point(16, 72);
			this.label10.Name = "label10";
			this.label10.Size = new System.Drawing.Size(72, 23);
			this.label10.TabIndex = 36;
			this.label10.Text = "销售编号";
			// 
			// textSaleDate
			// 
			this.textSaleDate.Location = new System.Drawing.Point(400, 160);
			this.textSaleDate.Name = "textSaleDate";
			this.textSaleDate.Size = new System.Drawing.Size(120, 23);
			this.textSaleDate.TabIndex = 35;
			this.textSaleDate.Text = "";
			// 
			// textSalePrice
			// 
			this.textSalePrice.Location = new System.Drawing.Point(400, 120);
			this.textSalePrice.Name = "textSalePrice";
			this.textSalePrice.Size = new System.Drawing.Size(120, 23);
			this.textSalePrice.TabIndex = 34;
			this.textSalePrice.Text = "";
			// 
			// textSaleAmount
			// 
			this.textSaleAmount.Location = new System.Drawing.Point(400, 80);
			this.textSaleAmount.Name = "textSaleAmount";
			this.textSaleAmount.Size = new System.Drawing.Size(120, 23);
			this.textSaleAmount.TabIndex = 33;
			this.textSaleAmount.Text = "";
			// 
			// label7
			// 
			this.label7.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label7.Location = new System.Drawing.Point(320, 168);
			this.label7.Name = "label7";
			this.label7.Size = new System.Drawing.Size(56, 16);
			this.label7.TabIndex = 32;
			this.label7.Text = "销售日期";
			// 
			// label8
			// 
			this.label8.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label8.Location = new System.Drawing.Point(320, 128);
			this.label8.Name = "label8";
			this.label8.Size = new System.Drawing.Size(56, 23);
			this.label8.TabIndex = 31;
			this.label8.Text = "商品单价";
			// 
			// label9
			// 
			this.label9.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label9.Location = new System.Drawing.Point(320, 88);
			this.label9.Name = "label9";
			this.label9.Size = new System.Drawing.Size(72, 23);
			this.label9.TabIndex = 30;
			this.label9.Text = "销售数量";
			// 
			// textClientName
			// 
			this.textClientName.Location = new System.Drawing.Point(96, 136);
			this.textClientName.Name = "textClientName";
			this.textClientName.Size = new System.Drawing.Size(120, 23);
			this.textClientName.TabIndex = 29;
			this.textClientName.Text = "";
			// 
			// textClientId
			// 
			this.textClientId.Cursor = System.Windows.Forms.Cursors.Arrow;
			this.textClientId.Location = new System.Drawing.Point(96, 96);
			this.textClientId.Name = "textClientId";
			this.textClientId.Size = new System.Drawing.Size(120, 23);
			this.textClientId.TabIndex = 28;
			this.textClientId.Text = "";
			// 
			// label4
			// 
			this.label4.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label4.Location = new System.Drawing.Point(16, 144);
			this.label4.Name = "label4";
			this.label4.Size = new System.Drawing.Size(72, 23);
			this.label4.TabIndex = 27;
			this.label4.Text = "客户名称";
			// 
			// label6
			// 
			this.label6.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label6.Location = new System.Drawing.Point(16, 104);
			this.label6.Name = "label6";
			this.label6.Size = new System.Drawing.Size(72, 23);
			this.label6.TabIndex = 26;
			this.label6.Text = "客户编号";
			// 
			// lblDatasetPosition
			// 
			this.lblDatasetPosition.BackColor = System.Drawing.Color.White;
			this.lblDatasetPosition.Location = new System.Drawing.Point(104, 24);
			this.lblDatasetPosition.Name = "lblDatasetPosition";
			this.lblDatasetPosition.Size = new System.Drawing.Size(64, 23);
			this.lblDatasetPosition.TabIndex = 25;
			this.lblDatasetPosition.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
			// 
			// btnLast
			// 
			this.btnLast.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
			this.btnLast.Image = ((System.Drawing.Image)(resources.GetObject("btnLast.Image")));
			this.btnLast.Location = new System.Drawing.Point(224, 24);
			this.btnLast.Name = "btnLast";
			this.btnLast.Size = new System.Drawing.Size(40, 24);
			this.btnLast.TabIndex = 23;
			this.btnLast.Click += new System.EventHandler(this.btnLast_Click);
			// 
			// btnNext
			// 
			this.btnNext.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
			this.btnNext.Image = ((System.Drawing.Image)(resources.GetObject("btnNext.Image")));
			this.btnNext.Location = new System.Drawing.Point(176, 24);
			this.btnNext.Name = "btnNext";
			this.btnNext.Size = new System.Drawing.Size(40, 24);
			this.btnNext.TabIndex = 22;
			this.btnNext.Click += new System.EventHandler(this.btnNext_Click);
			// 
			// btnPrevious
			// 
			this.btnPrevious.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
			this.btnPrevious.Image = ((System.Drawing.Image)(resources.GetObject("btnPrevious.Image")));
			this.btnPrevious.Location = new System.Drawing.Point(56, 24);
			this.btnPrevious.Name = "btnPrevious";
			this.btnPrevious.Size = new System.Drawing.Size(40, 24);
			this.btnPrevious.TabIndex = 21;
			this.btnPrevious.Click += new System.EventHandler(this.btnPrevious_Click);
			// 
			// btnFirst
			// 
			this.btnFirst.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
			this.btnFirst.Image = ((System.Drawing.Image)(resources.GetObject("btnFirst.Image")));
			this.btnFirst.Location = new System.Drawing.Point(8, 24);
			this.btnFirst.Name = "btnFirst";
			this.btnFirst.Size = new System.Drawing.Size(40, 24);
			this.btnFirst.TabIndex = 20;
			this.btnFirst.Click += new System.EventHandler(this.btnFirst_Click);
			// 
			// textProductUnit
			// 
			this.textProductUnit.Location = new System.Drawing.Point(400, 40);
			this.textProductUnit.Name = "textProductUnit";
			this.textProductUnit.Size = new System.Drawing.Size(120, 23);
			this.textProductUnit.TabIndex = 13;
			this.textProductUnit.Text = "";
			// 
			// textProductSpecity
			// 
			this.textProductSpecity.Location = new System.Drawing.Point(96, 256);
			this.textProductSpecity.Name = "textProductSpecity";
			this.textProductSpecity.Size = new System.Drawing.Size(120, 23);
			this.textProductSpecity.TabIndex = 12;
			this.textProductSpecity.Text = "";
			// 
			// textProductName
			// 
			this.textProductName.Location = new System.Drawing.Point(96, 216);
			this.textProductName.Name = "textProductName";
			this.textProductName.Size = new System.Drawing.Size(120, 23);
			this.textProductName.TabIndex = 11;
			this.textProductName.Text = "";
			// 
			// textProductId
			// 
			this.textProductId.Cursor = System.Windows.Forms.Cursors.Arrow;
			this.textProductId.Location = new System.Drawing.Point(96, 176);
			this.textProductId.Name = "textProductId";
			this.textProductId.Size = new System.Drawing.Size(120, 23);
			this.textProductId.TabIndex = 10;
			this.textProductId.Text = "";
			// 
			// groupBox2
			// 
			this.groupBox2.Controls.Add(this.textSaleRemark);
			this.groupBox2.Location = new System.Drawing.Point(320, 192);
			this.groupBox2.Name = "groupBox2";
			this.groupBox2.Size = new System.Drawing.Size(224, 112);
			this.groupBox2.TabIndex = 9;
			this.groupBox2.TabStop = false;
			this.groupBox2.Text = "信息备注";
			// 
			// textSaleRemark
			// 
			this.textSaleRemark.Location = new System.Drawing.Point(16, 24);
			this.textSaleRemark.Multiline = true;
			this.textSaleRemark.Name = "textSaleRemark";
			this.textSaleRemark.Size = new System.Drawing.Size(192, 72);
			this.textSaleRemark.TabIndex = 0;
			this.textSaleRemark.Text = "";
			this.textSaleRemark.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
			// 
			// label5
			// 
			this.label5.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label5.Location = new System.Drawing.Point(320, 48);
			this.label5.Name = "label5";
			this.label5.Size = new System.Drawing.Size(64, 23);
			this.label5.TabIndex = 4;
			this.label5.Text = "计量单位";
			// 
			// label3
			// 
			this.label3.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
			this.label3.Location = new System.Drawing.Point(16, 264);
			this.label3.Name = "label3";
			this.label3.Size = new System.Drawing.Size(72, 23);
			this.label3.TabIndex = 2;
			this.label3.Text = "商品类别";
			// 
			// label2
			// 

⌨️ 快捷键说明

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