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

📄 staffquery.cs

📁 工资结算系统 拥有权限控制 临时工资表 自动导入导出Excel 以及邮件群发功能
💻 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;
using HrSalary.util;
using HrSalary.salary;

namespace HrSalary.employee
{
	/// <summary>
	/// EmployeeQuery 的摘要说明。
	/// </summary>
	public class StaffQuery : System.Windows.Forms.Form
	{
		private System.Windows.Forms.GroupBox groupBox1;
		private System.Windows.Forms.DataGrid dataGrid1;
		private System.Windows.Forms.Label label1;
		private System.Windows.Forms.TextBox totalNumber;
		private System.Windows.Forms.TextBox empid;
		private System.Windows.Forms.TextBox empname;
		/// <summary>
		/// 必需的设计器变量。
		/// </summary>
		private System.ComponentModel.Container components = null;
		private System.Windows.Forms.DataGridTableStyle dataGridTableStyle1;
		private System.Windows.Forms.DataGridTextBoxColumn dataGridTextBoxColumn1;
		private System.Windows.Forms.DataGridTextBoxColumn dataGridTextBoxColumn2;
		private System.Windows.Forms.DataGridTextBoxColumn dataGridTextBoxColumn3;
		private System.Windows.Forms.DataGridTextBoxColumn dataGridTextBoxColumn4;
		private OleDbConnection dbCon = null;
		private OleDbDataAdapter dbAdapter = null;
		private System.Windows.Forms.Button button1;
		private System.Windows.Forms.CheckBox idCheck;
		private System.Windows.Forms.CheckBox nameCheck;
		private System.Windows.Forms.ContextMenu contextMenu1;
		private System.Windows.Forms.MenuItem menuItem1;
		private System.Windows.Forms.MenuItem menuItem2;
		private System.Windows.Forms.MenuItem menuItem3;
		private System.Windows.Forms.MenuItem menuItem4;
		private System.Windows.Forms.Button button3;
		private System.Windows.Forms.TextBox bankcard;
		private System.Windows.Forms.CheckBox bankcardcheck;
		private System.Windows.Forms.TextBox email;
		private System.Windows.Forms.CheckBox emailcheck;
		private System.Windows.Forms.GroupBox groupBox2;
		private System.Windows.Forms.Button Excel_button8;
		private DataSet ds = null;

		public StaffQuery()
		{
			//
			// 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.groupBox1 = new System.Windows.Forms.GroupBox();
			this.bankcard = new System.Windows.Forms.TextBox();
			this.bankcardcheck = new System.Windows.Forms.CheckBox();
			this.email = new System.Windows.Forms.TextBox();
			this.emailcheck = new System.Windows.Forms.CheckBox();
			this.button3 = new System.Windows.Forms.Button();
			this.button1 = new System.Windows.Forms.Button();
			this.empname = new System.Windows.Forms.TextBox();
			this.nameCheck = new System.Windows.Forms.CheckBox();
			this.empid = new System.Windows.Forms.TextBox();
			this.idCheck = new System.Windows.Forms.CheckBox();
			this.dataGrid1 = new System.Windows.Forms.DataGrid();
			this.contextMenu1 = new System.Windows.Forms.ContextMenu();
			this.menuItem1 = new System.Windows.Forms.MenuItem();
			this.menuItem2 = new System.Windows.Forms.MenuItem();
			this.menuItem4 = new System.Windows.Forms.MenuItem();
			this.dataGridTableStyle1 = new System.Windows.Forms.DataGridTableStyle();
			this.dataGridTextBoxColumn1 = new System.Windows.Forms.DataGridTextBoxColumn();
			this.dataGridTextBoxColumn2 = new System.Windows.Forms.DataGridTextBoxColumn();
			this.dataGridTextBoxColumn3 = new System.Windows.Forms.DataGridTextBoxColumn();
			this.dataGridTextBoxColumn4 = new System.Windows.Forms.DataGridTextBoxColumn();
			this.menuItem3 = new System.Windows.Forms.MenuItem();
			this.label1 = new System.Windows.Forms.Label();
			this.totalNumber = new System.Windows.Forms.TextBox();
			this.groupBox2 = new System.Windows.Forms.GroupBox();
			this.Excel_button8 = new System.Windows.Forms.Button();
			this.groupBox1.SuspendLayout();
			((System.ComponentModel.ISupportInitialize)(this.dataGrid1)).BeginInit();
			this.groupBox2.SuspendLayout();
			this.SuspendLayout();
			// 
			// groupBox1
			// 
			this.groupBox1.BackColor = System.Drawing.Color.AliceBlue;
			this.groupBox1.Controls.Add(this.bankcard);
			this.groupBox1.Controls.Add(this.bankcardcheck);
			this.groupBox1.Controls.Add(this.email);
			this.groupBox1.Controls.Add(this.emailcheck);
			this.groupBox1.Controls.Add(this.button3);
			this.groupBox1.Controls.Add(this.button1);
			this.groupBox1.Controls.Add(this.empname);
			this.groupBox1.Controls.Add(this.nameCheck);
			this.groupBox1.Controls.Add(this.empid);
			this.groupBox1.Controls.Add(this.idCheck);
			this.groupBox1.Location = new System.Drawing.Point(8, 0);
			this.groupBox1.Name = "groupBox1";
			this.groupBox1.Size = new System.Drawing.Size(688, 80);
			this.groupBox1.TabIndex = 0;
			this.groupBox1.TabStop = false;
			this.groupBox1.Text = "员工信息查询";
			// 
			// bankcard
			// 
			this.bankcard.Location = new System.Drawing.Point(368, 48);
			this.bankcard.Name = "bankcard";
			this.bankcard.Size = new System.Drawing.Size(136, 21);
			this.bankcard.TabIndex = 12;
			this.bankcard.Text = "";
			// 
			// bankcardcheck
			// 
			this.bankcardcheck.Location = new System.Drawing.Point(296, 48);
			this.bankcardcheck.Name = "bankcardcheck";
			this.bankcardcheck.Size = new System.Drawing.Size(80, 24);
			this.bankcardcheck.TabIndex = 11;
			this.bankcardcheck.Text = "银行卡号";
			// 
			// email
			// 
			this.email.Location = new System.Drawing.Point(112, 48);
			this.email.Name = "email";
			this.email.Size = new System.Drawing.Size(136, 21);
			this.email.TabIndex = 10;
			this.email.Text = "";
			// 
			// emailcheck
			// 
			this.emailcheck.Location = new System.Drawing.Point(48, 48);
			this.emailcheck.Name = "emailcheck";
			this.emailcheck.Size = new System.Drawing.Size(80, 24);
			this.emailcheck.TabIndex = 9;
			this.emailcheck.Text = "email";
			// 
			// button3
			// 
			this.button3.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
			this.button3.Location = new System.Drawing.Point(544, 16);
			this.button3.Name = "button3";
			this.button3.Size = new System.Drawing.Size(104, 24);
			this.button3.TabIndex = 8;
			this.button3.Text = "查询已删除信息";
			this.button3.Click += new System.EventHandler(this.button3_Click);
			// 
			// button1
			// 
			this.button1.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
			this.button1.Location = new System.Drawing.Point(544, 48);
			this.button1.Name = "button1";
			this.button1.Size = new System.Drawing.Size(104, 24);
			this.button1.TabIndex = 7;
			this.button1.Text = "查询员工信息";
			this.button1.Click += new System.EventHandler(this.button1_Click);
			// 
			// empname
			// 
			this.empname.Location = new System.Drawing.Point(368, 16);
			this.empname.Name = "empname";
			this.empname.Size = new System.Drawing.Size(136, 21);
			this.empname.TabIndex = 4;
			this.empname.Text = "";
			// 
			// nameCheck
			// 
			this.nameCheck.Location = new System.Drawing.Point(296, 16);
			this.nameCheck.Name = "nameCheck";
			this.nameCheck.Size = new System.Drawing.Size(80, 24);
			this.nameCheck.TabIndex = 3;
			this.nameCheck.Text = "姓名";
			// 
			// empid
			// 
			this.empid.Location = new System.Drawing.Point(112, 16);
			this.empid.Name = "empid";
			this.empid.Size = new System.Drawing.Size(136, 21);
			this.empid.TabIndex = 2;
			this.empid.Text = "";
			// 
			// idCheck
			// 
			this.idCheck.Location = new System.Drawing.Point(48, 16);
			this.idCheck.Name = "idCheck";
			this.idCheck.Size = new System.Drawing.Size(80, 24);
			this.idCheck.TabIndex = 1;
			this.idCheck.Text = "编号";
			// 
			// dataGrid1
			// 
			this.dataGrid1.BackgroundColor = System.Drawing.SystemColors.ActiveCaptionText;
			this.dataGrid1.CaptionVisible = false;
			this.dataGrid1.ContextMenu = this.contextMenu1;
			this.dataGrid1.DataMember = "";
			this.dataGrid1.HeaderForeColor = System.Drawing.SystemColors.ControlText;
			this.dataGrid1.Location = new System.Drawing.Point(48, 88);
			this.dataGrid1.Name = "dataGrid1";
			this.dataGrid1.ReadOnly = true;
			this.dataGrid1.Size = new System.Drawing.Size(608, 280);
			this.dataGrid1.TabIndex = 1;
			this.dataGrid1.TableStyles.AddRange(new System.Windows.Forms.DataGridTableStyle[] {
																								  this.dataGridTableStyle1});
			this.dataGrid1.MouseUp += new System.Windows.Forms.MouseEventHandler(this.dataGrid1_MouseUp);
			// 
			// contextMenu1
			// 
			this.contextMenu1.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
																						 this.menuItem1,
																						 this.menuItem2,
																						 this.menuItem4});
			// 
			// menuItem1
			// 
			this.menuItem1.Index = 0;
			this.menuItem1.Text = "修改选择员工信息";
			this.menuItem1.Click += new System.EventHandler(this.menuItem1_Click);
			// 
			// menuItem2
			// 
			this.menuItem2.Index = 1;
			this.menuItem2.Text = "删除该条信息";
			this.menuItem2.Click += new System.EventHandler(this.menuItem2_Click);
			// 
			// menuItem4
			// 
			this.menuItem4.Index = 2;
			this.menuItem4.Text = "恢复该条信息";
			this.menuItem4.Click += new System.EventHandler(this.menuItem4_Click);
			// 
			// dataGridTableStyle1
			// 
			this.dataGridTableStyle1.DataGrid = this.dataGrid1;
			this.dataGridTableStyle1.GridColumnStyles.AddRange(new System.Windows.Forms.DataGridColumnStyle[] {
																												  this.dataGridTextBoxColumn1,
																												  this.dataGridTextBoxColumn2,
																												  this.dataGridTextBoxColumn3,
																												  this.dataGridTextBoxColumn4});
			this.dataGridTableStyle1.HeaderForeColor = System.Drawing.SystemColors.ControlText;
			this.dataGridTableStyle1.MappingName = "employee";
			// 
			// dataGridTextBoxColumn1
			// 
			this.dataGridTextBoxColumn1.Format = "";
			this.dataGridTextBoxColumn1.FormatInfo = null;
			this.dataGridTextBoxColumn1.HeaderText = "编号";
			this.dataGridTextBoxColumn1.MappingName = "编号";
			this.dataGridTextBoxColumn1.Width = 45;
			// 
			// dataGridTextBoxColumn2
			// 
			this.dataGridTextBoxColumn2.Format = "";
			this.dataGridTextBoxColumn2.FormatInfo = null;
			this.dataGridTextBoxColumn2.HeaderText = "姓名";
			this.dataGridTextBoxColumn2.MappingName = "姓名";
			this.dataGridTextBoxColumn2.Width = 105;
			// 
			// dataGridTextBoxColumn3
			// 
			this.dataGridTextBoxColumn3.Format = "";
			this.dataGridTextBoxColumn3.FormatInfo = null;
			this.dataGridTextBoxColumn3.HeaderText = "Email";
			this.dataGridTextBoxColumn3.MappingName = "Email";
			this.dataGridTextBoxColumn3.Width = 205;
			// 
			// dataGridTextBoxColumn4
			// 
			this.dataGridTextBoxColumn4.Format = "";
			this.dataGridTextBoxColumn4.FormatInfo = null;
			this.dataGridTextBoxColumn4.HeaderText = "银行卡号";
			this.dataGridTextBoxColumn4.MappingName = "银行卡号";
			this.dataGridTextBoxColumn4.Width = 175;
			// 
			// menuItem3
			// 
			this.menuItem3.Index = -1;
			this.menuItem3.Text = "";
			// 
			// label1
			// 
			this.label1.AutoSize = true;
			this.label1.Location = new System.Drawing.Point(264, 312);
			this.label1.Name = "label1";
			this.label1.Size = new System.Drawing.Size(66, 17);
			this.label1.TabIndex = 2;
			this.label1.Text = "共有人数:";
			// 
			// totalNumber
			// 

⌨️ 快捷键说明

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