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

📄 frmproduct.cs

📁 本论文叙述了联机考试系统的现状以及C#语言的概况。重点介绍了联机考试系统的实现过程:包括系统分析、 系统调查、 数据流程分析、功能设计、 数据库设计、 系统物理配置方案、 系统实现、 系统测试和调试。
💻 CS
📖 第 1 页 / 共 2 页
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.Data.OleDb;

namespace SupermarketProject
{

	///	<summary>

	///	Summary	description	for	frmProduct.

	///	</summary>
	public class frmProduct	: System.Windows.Forms.Form
	{
		private	System.Windows.Forms.Label lblPrdName;
		private	System.Windows.Forms.Label lblPrdNo;
		private	System.Windows.Forms.Label lblQty;
		private	System.Windows.Forms.Label lblDesc;
		private	System.Windows.Forms.Label lblProdCat;
		private	System.Windows.Forms.Label lblUnit;
		private	System.Windows.Forms.TextBox txtProdName;
		private	System.Windows.Forms.TextBox txtProdNo;
		private	System.Windows.Forms.TextBox txtQty;
		private	System.Windows.Forms.TextBox txtDesc;
		private	System.Windows.Forms.TextBox txtUnit;
		private	System.Windows.Forms.Button	btnOK;
		private	System.Windows.Forms.Button	btnCancel;
		private	System.Windows.Forms.ComboBox cboPrdCat;
		public string catCode,flvlCatCode;
		private	System.Windows.Forms.Label lblProdId;
		private	System.Windows.Forms.TextBox txtProdId;
		private	System.ComponentModel.IContainer components;
		private	System.Windows.Forms.ErrorProvider errProduct;
		//other	variables
		public string errorMsg;
		private	System.Windows.Forms.HelpProvider hlpNewProduct;
		private	System.Windows.Forms.ToolTip tipNewProduct;
		public bool	allValidated = false;
        private Settings settings;
		
		public frmProduct()
		{
			//
			// Required for Windows Form Designer support

			//
			
			InitializeComponent();
			settings =new Settings();

			this.hlpNewProduct.HelpNamespace = settings.uiDirectory+ @"\HELP\SupermarketHelp.chm"; 

			//

			// TODO: Add any constructor code after InitializeComponent call

			//

		}


		/// <summary>

		/// Clean up any resources being used.

		/// </summary>

		protected override void Dispose( bool disposing )
		{
			if( disposing )
			{
				if(components != null)
				{
					components.Dispose();
				}
			}

			base.Dispose( disposing );
		}

		#region Windows Form Designer generated code

		/// <summary>

		/// Required method for Designer support - do not modify

		/// the contents of this method with the code editor.

		/// </summary>

		private void InitializeComponent()

		{
			this.components = new System.ComponentModel.Container();
			this.lblPrdName = new System.Windows.Forms.Label();
			this.lblPrdNo = new System.Windows.Forms.Label();
			this.lblQty = new System.Windows.Forms.Label();
			this.lblDesc = new System.Windows.Forms.Label();
			this.lblProdCat = new System.Windows.Forms.Label();
			this.lblUnit = new System.Windows.Forms.Label();
			this.txtProdName = new System.Windows.Forms.TextBox();
			this.txtProdNo = new System.Windows.Forms.TextBox();
			this.txtQty = new System.Windows.Forms.TextBox();
			this.txtDesc = new System.Windows.Forms.TextBox();
			this.txtUnit = new System.Windows.Forms.TextBox();
			this.btnOK = new System.Windows.Forms.Button();
			this.btnCancel = new System.Windows.Forms.Button();
			this.cboPrdCat = new System.Windows.Forms.ComboBox();
			this.lblProdId = new System.Windows.Forms.Label();
			this.txtProdId = new System.Windows.Forms.TextBox();
			this.errProduct = new System.Windows.Forms.ErrorProvider();
			this.hlpNewProduct = new System.Windows.Forms.HelpProvider();
			this.tipNewProduct = new System.Windows.Forms.ToolTip(this.components);
			this.SuspendLayout();
			// 
			// lblPrdName
			// 
			this.lblPrdName.Location = new System.Drawing.Point(10, 34);
			this.lblPrdName.Name = "lblPrdName";
			this.lblPrdName.Size = new System.Drawing.Size(124, 26);
			this.lblPrdName.TabIndex = 0;
			this.lblPrdName.Text = "名称";
			this.lblPrdName.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
			// 
			// lblPrdNo
			// 
			this.lblPrdNo.Location = new System.Drawing.Point(298, 43);
			this.lblPrdNo.Name = "lblPrdNo";
			this.lblPrdNo.Size = new System.Drawing.Size(76, 25);
			this.lblPrdNo.TabIndex = 10;
			this.lblPrdNo.Text = "产品型号";
			this.lblPrdNo.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
			// 
			// lblQty
			// 
			this.lblQty.Location = new System.Drawing.Point(10, 103);
			this.lblQty.Name = "lblQty";
			this.lblQty.Size = new System.Drawing.Size(124, 26);
			this.lblQty.TabIndex = 2;
			this.lblQty.Text = "数量";
			this.lblQty.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
			// 
			// lblDesc
			// 
			this.lblDesc.Location = new System.Drawing.Point(10, 164);
			this.lblDesc.Name = "lblDesc";
			this.lblDesc.Size = new System.Drawing.Size(124, 26);
			this.lblDesc.TabIndex = 4;
			this.lblDesc.Text = "说明";
			this.lblDesc.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
			// 
			// lblProdCat
			// 
			this.lblProdCat.Location = new System.Drawing.Point(10, 241);
			this.lblProdCat.Name = "lblProdCat";
			this.lblProdCat.Size = new System.Drawing.Size(124, 26);
			this.lblProdCat.TabIndex = 6;
			this.lblProdCat.Text = "产品类别";
			this.lblProdCat.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
			// 
			// lblUnit
			// 
			this.lblUnit.Location = new System.Drawing.Point(10, 293);
			this.lblUnit.Name = "lblUnit";
			this.lblUnit.Size = new System.Drawing.Size(134, 26);
			this.lblUnit.TabIndex = 8;
			this.lblUnit.Text = "单位";
			this.lblUnit.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
			// 
			// txtProdName
			// 
			this.txtProdName.Location = new System.Drawing.Point(154, 34);
			this.txtProdName.Name = "txtProdName";
			this.txtProdName.Size = new System.Drawing.Size(120, 21);
			this.txtProdName.TabIndex = 1;
			this.txtProdName.Text = "";
			this.txtProdName.Leave += new System.EventHandler(this.txtProdName_Leave);
			// 
			// txtProdNo
			// 
			this.txtProdNo.Location = new System.Drawing.Point(403, 43);
			this.txtProdNo.Name = "txtProdNo";
			this.txtProdNo.ReadOnly = true;
			this.txtProdNo.Size = new System.Drawing.Size(120, 21);
			this.txtProdNo.TabIndex = 11;
			this.txtProdNo.Text = "";
			// 
			// txtQty
			// 
			this.txtQty.Location = new System.Drawing.Point(154, 103);
			this.txtQty.Name = "txtQty";
			this.txtQty.Size = new System.Drawing.Size(120, 21);
			this.txtQty.TabIndex = 3;
			this.txtQty.Text = "";
			this.txtQty.Leave += new System.EventHandler(this.txtQty_Leave);
			// 
			// txtDesc
			// 
			this.txtDesc.Location = new System.Drawing.Point(154, 146);
			this.txtDesc.Multiline = true;
			this.txtDesc.Name = "txtDesc";
			this.txtDesc.Size = new System.Drawing.Size(384, 78);
			this.txtDesc.TabIndex = 5;
			this.txtDesc.Text = "";
			this.txtDesc.Leave += new System.EventHandler(this.txtDesc_Leave);
			// 
			// txtUnit
			// 
			this.txtUnit.Location = new System.Drawing.Point(154, 293);
			this.txtUnit.Name = "txtUnit";
			this.txtUnit.Size = new System.Drawing.Size(120, 21);
			this.txtUnit.TabIndex = 9;
			this.txtUnit.Text = "";
			this.txtUnit.Leave += new System.EventHandler(this.txtUnit_Leave);
			// 
			// btnOK
			// 
			this.btnOK.Location = new System.Drawing.Point(346, 319);
			this.btnOK.Name = "btnOK";
			this.btnOK.Size = new System.Drawing.Size(90, 34);
			this.btnOK.TabIndex = 14;
			this.btnOK.Text = "确定(&O)";
			this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
			// 
			// btnCancel
			// 
			this.btnCancel.Location = new System.Drawing.Point(461, 319);
			this.btnCancel.Name = "btnCancel";
			this.btnCancel.Size = new System.Drawing.Size(90, 34);
			this.btnCancel.TabIndex = 15;
			this.btnCancel.Text = "取消(&C)";
			this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click);
			// 
			// cboPrdCat
			// 
			this.cboPrdCat.Location = new System.Drawing.Point(154, 241);
			this.cboPrdCat.Name = "cboPrdCat";
			this.cboPrdCat.Size = new System.Drawing.Size(124, 20);
			this.cboPrdCat.TabIndex = 7;
			this.cboPrdCat.Leave += new System.EventHandler(this.cboPrdCat_Leave);
			// 
			// lblProdId
			// 
			this.lblProdId.Location = new System.Drawing.Point(298, 78);
			this.lblProdId.Name = "lblProdId";
			this.lblProdId.Size = new System.Drawing.Size(120, 24);
			this.lblProdId.TabIndex = 12;
			this.lblProdId.Text = "产品标识";
			this.lblProdId.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
			// 
			// txtProdId
			// 
			this.txtProdId.Location = new System.Drawing.Point(403, 78);
			this.txtProdId.Name = "txtProdId";
			this.txtProdId.ReadOnly = true;
			this.txtProdId.Size = new System.Drawing.Size(120, 21);
			this.txtProdId.TabIndex = 13;
			this.txtProdId.Text = "";
			// 
			// errProduct
			// 
			this.errProduct.ContainerControl = this;
			// 

⌨️ 快捷键说明

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