📄 viewitem.cs
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data.SqlClient;
using System.Data;
namespace Login
{
/// <summary>
/// ViewEmployee 的摘要说明。
/// </summary>
public class ViewItem : System.Windows.Forms.Form
{
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox tbID;
private System.Windows.Forms.Button bView;
private System.Windows.Forms.Button bViewAll;
private System.Windows.Forms.Button btExit;
private System.Data.SqlClient.SqlConnection sqlConnection_Staff;
private System.Data.SqlClient.SqlDataAdapter sqlDataAdapter_Staff;
private System.Windows.Forms.GroupBox groupBox1;
private int choose;
private System.Data.SqlClient.SqlDataAdapter sqlDataAdapter_Comm;
private System.Data.DataSet dataSetView;
private System.Windows.Forms.DataGrid dataGrid_View;
private System.Data.SqlClient.SqlDataAdapter sqlDataAdapter_Vip;
private System.Data.SqlClient.SqlCommand sqlSelectCommand1;
private System.Data.SqlClient.SqlCommand sqlInsertCommand1;
private System.Data.SqlClient.SqlCommand sqlSelectCommand3;
private System.Data.SqlClient.SqlCommand sqlInsertCommand3;
private System.Data.SqlClient.SqlCommand sqlUpdateCommand2;
private System.Data.SqlClient.SqlCommand sqlDeleteCommand2;
private System.Data.SqlClient.SqlCommand sqlSelectCommand2;
private System.Data.SqlClient.SqlCommand sqlInsertCommand2;
private System.Data.SqlClient.SqlCommand sqlUpdateCommand1;
private System.Data.SqlClient.SqlCommand sqlDeleteCommand1;
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.Container components = null;
public ViewItem()
{
//
// Windows 窗体设计器支持所必需的
//
InitializeComponent();
//
// TODO: 在 InitializeComponent 调用后添加任何构造函数代码
//
}
public ViewItem(int i)
{
//
// Windows 窗体设计器支持所必需的
//
choose=i;
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(ViewItem));
this.label1 = new System.Windows.Forms.Label();
this.tbID = new System.Windows.Forms.TextBox();
this.bView = new System.Windows.Forms.Button();
this.bViewAll = new System.Windows.Forms.Button();
this.btExit = new System.Windows.Forms.Button();
this.sqlConnection_Staff = new System.Data.SqlClient.SqlConnection();
this.sqlDataAdapter_Staff = new System.Data.SqlClient.SqlDataAdapter();
this.sqlInsertCommand1 = new System.Data.SqlClient.SqlCommand();
this.sqlSelectCommand1 = new System.Data.SqlClient.SqlCommand();
this.dataGrid_View = new System.Windows.Forms.DataGrid();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.sqlDataAdapter_Comm = new System.Data.SqlClient.SqlDataAdapter();
this.dataSetView = new System.Data.DataSet();
this.sqlDataAdapter_Vip = new System.Data.SqlClient.SqlDataAdapter();
this.sqlSelectCommand3 = new System.Data.SqlClient.SqlCommand();
this.sqlInsertCommand3 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand2 = new System.Data.SqlClient.SqlCommand();
this.sqlDeleteCommand2 = new System.Data.SqlClient.SqlCommand();
this.sqlSelectCommand2 = new System.Data.SqlClient.SqlCommand();
this.sqlInsertCommand2 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand1 = new System.Data.SqlClient.SqlCommand();
this.sqlDeleteCommand1 = new System.Data.SqlClient.SqlCommand();
((System.ComponentModel.ISupportInitialize)(this.dataGrid_View)).BeginInit();
this.groupBox1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataSetView)).BeginInit();
this.SuspendLayout();
//
// label1
//
this.label1.BackColor = System.Drawing.Color.Transparent;
this.label1.Location = new System.Drawing.Point(240, 72);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(32, 16);
this.label1.TabIndex = 0;
this.label1.Text = "ID:";
//
// tbID
//
this.tbID.Location = new System.Drawing.Point(280, 64);
this.tbID.Name = "tbID";
this.tbID.TabIndex = 1;
this.tbID.Text = "";
//
// bView
//
this.bView.Location = new System.Drawing.Point(40, 32);
this.bView.Name = "bView";
this.bView.TabIndex = 2;
this.bView.Text = "查看";
this.bView.Click += new System.EventHandler(this.bView_Click);
//
// bViewAll
//
this.bViewAll.Location = new System.Drawing.Point(160, 32);
this.bViewAll.Name = "bViewAll";
this.bViewAll.Size = new System.Drawing.Size(88, 23);
this.bViewAll.TabIndex = 3;
this.bViewAll.Text = "查看所有";
this.bViewAll.Click += new System.EventHandler(this.bViewAll_Click);
//
// btExit
//
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -