📄 form5.cs
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data ;using System.Data.SqlClient ;
namespace lzl061111152357good5
{
/// <summary>
/// Form5 的摘要说明。
/// </summary>
public class Form5 : System.Windows.Forms.Form
{
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TabControl tabControl1;
private System.Windows.Forms.TabPage tabPage1;
private System.Windows.Forms.TabPage tabPage2;
private System.Windows.Forms.DataGrid dataGrid1;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.TextBox textBox1;
private System.Windows.Forms.TextBox textBox2;
private System.Windows.Forms.TextBox textBox3;
private System.Windows.Forms.PictureBox pictureBox2;
private System.Windows.Forms.Button button3;
private System.Windows.Forms.Button button4;
private System.Windows.Forms.Button button5;
private System.Windows.Forms.Button button6;
private System.Windows.Forms.Button button7;
private System.Windows.Forms.Button button8;
private System.Windows.Forms.ComboBox comboBox1;
private System.Windows.Forms.ComboBox comboBox2;
lzlMain lzl;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox textBox4;
private System.Windows.Forms.PictureBox pictureBox3;
//private BindingManagerBase MyBind;
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.Container components = null;
public Form5()
{
//
// 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(Form5));
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.tabControl1 = new System.Windows.Forms.TabControl();
this.tabPage1 = new System.Windows.Forms.TabPage();
this.button2 = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.dataGrid1 = new System.Windows.Forms.DataGrid();
this.tabPage2 = new System.Windows.Forms.TabPage();
this.pictureBox3 = new System.Windows.Forms.PictureBox();
this.textBox4 = new System.Windows.Forms.TextBox();
this.label1 = new System.Windows.Forms.Label();
this.comboBox2 = new System.Windows.Forms.ComboBox();
this.comboBox1 = new System.Windows.Forms.ComboBox();
this.button8 = new System.Windows.Forms.Button();
this.button7 = new System.Windows.Forms.Button();
this.button6 = new System.Windows.Forms.Button();
this.button5 = new System.Windows.Forms.Button();
this.button4 = new System.Windows.Forms.Button();
this.button3 = new System.Windows.Forms.Button();
this.pictureBox2 = new System.Windows.Forms.PictureBox();
this.textBox3 = new System.Windows.Forms.TextBox();
this.textBox2 = new System.Windows.Forms.TextBox();
this.textBox1 = new System.Windows.Forms.TextBox();
this.label5 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.groupBox1.SuspendLayout();
this.tabControl1.SuspendLayout();
this.tabPage1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGrid1)).BeginInit();
this.tabPage2.SuspendLayout();
this.SuspendLayout();
//
// pictureBox1
//
this.pictureBox1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.pictureBox1.Image = ((System.Drawing.Image)(resources.GetObject("pictureBox1.Image")));
this.pictureBox1.Location = new System.Drawing.Point(0, 0);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(440, 72);
this.pictureBox1.TabIndex = 0;
this.pictureBox1.TabStop = false;
//
// groupBox1
//
this.groupBox1.Controls.Add(this.tabControl1);
this.groupBox1.Location = new System.Drawing.Point(8, 72);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(424, 264);
this.groupBox1.TabIndex = 1;
this.groupBox1.TabStop = false;
//
// tabControl1
//
this.tabControl1.Appearance = System.Windows.Forms.TabAppearance.FlatButtons;
this.tabControl1.Controls.Add(this.tabPage1);
this.tabControl1.Controls.Add(this.tabPage2);
this.tabControl1.Location = new System.Drawing.Point(8, 24);
this.tabControl1.Name = "tabControl1";
this.tabControl1.SelectedIndex = 0;
this.tabControl1.Size = new System.Drawing.Size(408, 232);
this.tabControl1.TabIndex = 3;
//
// tabPage1
//
this.tabPage1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.tabPage1.Controls.Add(this.button2);
this.tabPage1.Controls.Add(this.button1);
this.tabPage1.Controls.Add(this.dataGrid1);
this.tabPage1.Location = new System.Drawing.Point(4, 24);
this.tabPage1.Name = "tabPage1";
this.tabPage1.Size = new System.Drawing.Size(400, 204);
this.tabPage1.TabIndex = 0;
this.tabPage1.Text = "用户列表";
this.tabPage1.Click += new System.EventHandler(this.tabPage1_Click);
//
// button2
//
this.button2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.button2.Location = new System.Drawing.Point(16, 48);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(72, 24);
this.button2.TabIndex = 2;
this.button2.Text = "退出";
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// button1
//
this.button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.button1.Location = new System.Drawing.Point(16, 16);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(72, 24);
this.button1.TabIndex = 1;
this.button1.Text = "查询";
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// dataGrid1
//
this.dataGrid1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.dataGrid1.CaptionText = "所有用户";
this.dataGrid1.DataMember = "";
this.dataGrid1.FlatMode = true;
this.dataGrid1.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dataGrid1.Location = new System.Drawing.Point(104, 16);
this.dataGrid1.Name = "dataGrid1";
this.dataGrid1.Size = new System.Drawing.Size(280, 168);
this.dataGrid1.TabIndex = 0;
//
// tabPage2
//
this.tabPage2.BackColor = System.Drawing.SystemColors.Control;
this.tabPage2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.tabPage2.Controls.Add(this.pictureBox3);
this.tabPage2.Controls.Add(this.textBox4);
this.tabPage2.Controls.Add(this.label1);
this.tabPage2.Controls.Add(this.comboBox2);
this.tabPage2.Controls.Add(this.comboBox1);
this.tabPage2.Controls.Add(this.button8);
this.tabPage2.Controls.Add(this.button7);
this.tabPage2.Controls.Add(this.button6);
this.tabPage2.Controls.Add(this.button5);
this.tabPage2.Controls.Add(this.button4);
this.tabPage2.Controls.Add(this.button3);
this.tabPage2.Controls.Add(this.pictureBox2);
this.tabPage2.Controls.Add(this.textBox3);
this.tabPage2.Controls.Add(this.textBox2);
this.tabPage2.Controls.Add(this.textBox1);
this.tabPage2.Controls.Add(this.label5);
this.tabPage2.Controls.Add(this.label4);
this.tabPage2.Controls.Add(this.label3);
this.tabPage2.Controls.Add(this.label2);
this.tabPage2.Location = new System.Drawing.Point(4, 24);
this.tabPage2.Name = "tabPage2";
this.tabPage2.Size = new System.Drawing.Size(400, 204);
this.tabPage2.TabIndex = 1;
this.tabPage2.Text = "用户管理";
//
// pictureBox3
//
this.pictureBox3.Image = ((System.Drawing.Image)(resources.GetObject("pictureBox3.Image")));
this.pictureBox3.Location = new System.Drawing.Point(120, 8);
this.pictureBox3.Name = "pictureBox3";
this.pictureBox3.Size = new System.Drawing.Size(264, 176);
this.pictureBox3.TabIndex = 23;
this.pictureBox3.TabStop = false;
//
// textBox4
//
this.textBox4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.textBox4.Location = new System.Drawing.Point(232, 8);
this.textBox4.Name = "textBox4";
this.textBox4.Size = new System.Drawing.Size(152, 21);
this.textBox4.TabIndex = 22;
this.textBox4.Text = "";
this.textBox4.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
//
// label1
//
this.label1.Location = new System.Drawing.Point(128, 8);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(88, 24);
this.label1.TabIndex = 21;
this.label1.Text = "用户ID";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// comboBox2
//
this.comboBox2.Location = new System.Drawing.Point(232, 8);
this.comboBox2.Name = "comboBox2";
this.comboBox2.Size = new System.Drawing.Size(152, 20);
this.comboBox2.TabIndex = 19;
this.comboBox2.Visible = false;
//
// comboBox1
//
this.comboBox1.Items.AddRange(new object[] {
"普通用户",
"管理员",
"联系人"});
this.comboBox1.Location = new System.Drawing.Point(232, 136);
this.comboBox1.Name = "comboBox1";
this.comboBox1.Size = new System.Drawing.Size(152, 20);
this.comboBox1.TabIndex = 17;
this.comboBox1.Text = "普通用户";
//
// button8
//
this.button8.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.button8.Location = new System.Drawing.Point(312, 160);
this.button8.Name = "button8";
this.button8.Size = new System.Drawing.Size(72, 24);
this.button8.TabIndex = 15;
this.button8.Text = "取消";
this.button8.Click += new System.EventHandler(this.button8_Click);
//
// button7
//
this.button7.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.button7.Location = new System.Drawing.Point(16, 120);
this.button7.Name = "button7";
this.button7.Size = new System.Drawing.Size(72, 24);
this.button7.TabIndex = 14;
this.button7.Text = "退出";
this.button7.Click += new System.EventHandler(this.button7_Click);
//
// button6
//
this.button6.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.button6.Location = new System.Drawing.Point(232, 160);
this.button6.Name = "button6";
this.button6.Size = new System.Drawing.Size(72, 24);
this.button6.TabIndex = 13;
this.button6.Text = "确认";
this.button6.Click += new System.EventHandler(this.button6_Click);
//
// button5
//
this.button5.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.button5.Location = new System.Drawing.Point(16, 80);
this.button5.Name = "button5";
this.button5.Size = new System.Drawing.Size(72, 24);
this.button5.TabIndex = 12;
this.button5.Text = "删除用户";
this.button5.Click += new System.EventHandler(this.button5_Click);
//
// button4
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -