📄 usermanageform.cs
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
namespace WindowsApplication1
{
/// <summary>
/// UserManageForm 的摘要说明。
/// </summary>
public class UserManageForm : System.Windows.Forms.Form
{
private System.Windows.Forms.DataGrid dataGrid;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox textBox;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox textBox3;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.TextBox textBox4;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.TextBox textBox5;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.TextBox textBox6;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.ComboBox comboBox1;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Button button3;
private System.Windows.Forms.GroupBox groupBox1;
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.Container components = null;
public UserManageForm()
{
//
// 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.dataGrid = new System.Windows.Forms.DataGrid();
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.textBox = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label();
this.textBox3 = new System.Windows.Forms.TextBox();
this.label4 = new System.Windows.Forms.Label();
this.textBox4 = new System.Windows.Forms.TextBox();
this.label5 = new System.Windows.Forms.Label();
this.textBox5 = new System.Windows.Forms.TextBox();
this.label6 = new System.Windows.Forms.Label();
this.textBox6 = new System.Windows.Forms.TextBox();
this.label7 = new System.Windows.Forms.Label();
this.comboBox1 = new System.Windows.Forms.ComboBox();
this.button1 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.button3 = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox();
((System.ComponentModel.ISupportInitialize)(this.dataGrid)).BeginInit();
this.groupBox1.SuspendLayout();
this.SuspendLayout();
//
// dataGrid
//
this.dataGrid.DataMember = "";
this.dataGrid.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dataGrid.Location = new System.Drawing.Point(0, 40);
this.dataGrid.Name = "dataGrid";
this.dataGrid.Size = new System.Drawing.Size(488, 160);
this.dataGrid.TabIndex = 0;
//
// label1
//
this.label1.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.label1.Location = new System.Drawing.Point(200, 8);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(100, 24);
this.label1.TabIndex = 1;
this.label1.Text = "员工列表:";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// label2
//
this.label2.Location = new System.Drawing.Point(8, 24);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(48, 24);
this.label2.TabIndex = 2;
this.label2.Text = "姓名:";
this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// textBox
//
this.textBox.Location = new System.Drawing.Point(64, 24);
this.textBox.Name = "textBox";
this.textBox.Size = new System.Drawing.Size(88, 21);
this.textBox.TabIndex = 3;
this.textBox.Text = "";
//
// label3
//
this.label3.Location = new System.Drawing.Point(168, 24);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(48, 24);
this.label3.TabIndex = 4;
this.label3.Text = "性别:";
this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// textBox3
//
this.textBox3.Location = new System.Drawing.Point(384, 24);
this.textBox3.Name = "textBox3";
this.textBox3.Size = new System.Drawing.Size(88, 21);
this.textBox3.TabIndex = 7;
this.textBox3.Text = "";
//
// label4
//
this.label4.Location = new System.Drawing.Point(328, 24);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(48, 24);
this.label4.TabIndex = 6;
this.label4.Text = "年龄:";
this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// textBox4
//
this.textBox4.Location = new System.Drawing.Point(64, 56);
this.textBox4.Name = "textBox4";
this.textBox4.Size = new System.Drawing.Size(88, 21);
this.textBox4.TabIndex = 9;
this.textBox4.Text = "";
//
// label5
//
this.label5.Location = new System.Drawing.Point(8, 56);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(48, 24);
this.label5.TabIndex = 8;
this.label5.Text = "工龄:";
this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// textBox5
//
this.textBox5.Location = new System.Drawing.Point(224, 56);
this.textBox5.Name = "textBox5";
this.textBox5.Size = new System.Drawing.Size(88, 21);
this.textBox5.TabIndex = 11;
this.textBox5.Text = "";
//
// label6
//
this.label6.Location = new System.Drawing.Point(168, 56);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(48, 24);
this.label6.TabIndex = 10;
this.label6.Text = "职称:";
this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// textBox6
//
this.textBox6.Location = new System.Drawing.Point(384, 56);
this.textBox6.Name = "textBox6";
this.textBox6.Size = new System.Drawing.Size(88, 21);
this.textBox6.TabIndex = 13;
this.textBox6.Text = "";
//
// label7
//
this.label7.Location = new System.Drawing.Point(328, 56);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(48, 24);
this.label7.TabIndex = 12;
this.label7.Text = "权限:";
this.label7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// comboBox1
//
this.comboBox1.Items.AddRange(new object[] {
"男",
"女"});
this.comboBox1.Location = new System.Drawing.Point(224, 24);
this.comboBox1.Name = "comboBox1";
this.comboBox1.Size = new System.Drawing.Size(88, 20);
this.comboBox1.TabIndex = 14;
//
// button1
//
this.button1.Location = new System.Drawing.Point(88, 296);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(80, 24);
this.button1.TabIndex = 15;
this.button1.Text = "添加";
//
// button2
//
this.button2.Location = new System.Drawing.Point(200, 296);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(80, 24);
this.button2.TabIndex = 16;
this.button2.Text = "修改";
//
// button3
//
this.button3.Location = new System.Drawing.Point(312, 296);
this.button3.Name = "button3";
this.button3.Size = new System.Drawing.Size(80, 24);
this.button3.TabIndex = 17;
this.button3.Text = "删除";
//
// groupBox1
//
this.groupBox1.Controls.Add(this.textBox4);
this.groupBox1.Controls.Add(this.label4);
this.groupBox1.Controls.Add(this.textBox3);
this.groupBox1.Controls.Add(this.label3);
this.groupBox1.Controls.Add(this.textBox);
this.groupBox1.Controls.Add(this.label2);
this.groupBox1.Controls.Add(this.comboBox1);
this.groupBox1.Controls.Add(this.label7);
this.groupBox1.Controls.Add(this.textBox6);
this.groupBox1.Controls.Add(this.textBox5);
this.groupBox1.Controls.Add(this.label5);
this.groupBox1.Controls.Add(this.label6);
this.groupBox1.Location = new System.Drawing.Point(0, 200);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(488, 88);
this.groupBox1.TabIndex = 18;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "员工信息";
//
// UserManageForm
//
this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);
this.ClientSize = new System.Drawing.Size(488, 326);
this.Controls.Add(this.groupBox1);
this.Controls.Add(this.button3);
this.Controls.Add(this.button2);
this.Controls.Add(this.button1);
this.Controls.Add(this.label1);
this.Controls.Add(this.dataGrid);
this.Name = "UserManageForm";
this.Text = "员工管理";
((System.ComponentModel.ISupportInitialize)(this.dataGrid)).EndInit();
this.groupBox1.ResumeLayout(false);
this.ResumeLayout(false);
}
#endregion
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -