?? frmmain.cs
字號:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using Aptech.Student.DataAccess;
using Aptech.Student.Common;
namespace 學生管理系統
{
/// <summary>
/// Form1 的摘要說明。
/// </summary>
public class frmMain : System.Windows.Forms.Form
{
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Panel panel2;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TreeView tvClass;
private System.Windows.Forms.ListView lvStudent;
private System.Windows.Forms.ColumnHeader columnHeader1;
private System.Windows.Forms.ColumnHeader columnHeader2;
private System.Windows.Forms.ColumnHeader columnHeader3;
private System.Windows.Forms.ColumnHeader columnHeader4;
private System.Windows.Forms.ColumnHeader columnHeader5;
private System.Windows.Forms.ColumnHeader columnHeader6;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.ListView lvCourse;
private System.Windows.Forms.DataGrid dgScore;
private System.Windows.Forms.MainMenu mainMenu1;
private System.Windows.Forms.MenuItem menuItem1;
private System.Windows.Forms.MenuItem menuItem4;
private System.Windows.Forms.MenuItem menuItem5;
private System.Windows.Forms.MenuItem menuItem6;
private System.Windows.Forms.MenuItem menuItem7;
private System.Windows.Forms.MenuItem menuItem8;
private System.Windows.Forms.MenuItem menuItem2;
private System.Windows.Forms.MenuItem menuItem3;
private System.Windows.Forms.ImageList imageListMy;
private System.ComponentModel.IContainer components;
DataSet dsClass;
DataSet dsStudent;
public DataSet dsCourses;
DataSet dsScores;
public frmMain()
{
//
// 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.components = new System.ComponentModel.Container();
System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(frmMain));
this.panel1 = new System.Windows.Forms.Panel();
this.lvStudent = new System.Windows.Forms.ListView();
this.columnHeader1 = new System.Windows.Forms.ColumnHeader();
this.columnHeader2 = new System.Windows.Forms.ColumnHeader();
this.columnHeader3 = new System.Windows.Forms.ColumnHeader();
this.columnHeader4 = new System.Windows.Forms.ColumnHeader();
this.columnHeader5 = new System.Windows.Forms.ColumnHeader();
this.columnHeader6 = new System.Windows.Forms.ColumnHeader();
this.imageListMy = new System.Windows.Forms.ImageList(this.components);
this.tvClass = new System.Windows.Forms.TreeView();
this.label1 = new System.Windows.Forms.Label();
this.panel2 = new System.Windows.Forms.Panel();
this.dgScore = new System.Windows.Forms.DataGrid();
this.lvCourse = new System.Windows.Forms.ListView();
this.label2 = new System.Windows.Forms.Label();
this.mainMenu1 = new System.Windows.Forms.MainMenu();
this.menuItem1 = new System.Windows.Forms.MenuItem();
this.menuItem4 = new System.Windows.Forms.MenuItem();
this.menuItem5 = new System.Windows.Forms.MenuItem();
this.menuItem6 = new System.Windows.Forms.MenuItem();
this.menuItem7 = new System.Windows.Forms.MenuItem();
this.menuItem8 = new System.Windows.Forms.MenuItem();
this.menuItem2 = new System.Windows.Forms.MenuItem();
this.menuItem3 = new System.Windows.Forms.MenuItem();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dgScore)).BeginInit();
this.SuspendLayout();
//
// panel1
//
this.panel1.Controls.Add(this.lvStudent);
this.panel1.Controls.Add(this.tvClass);
this.panel1.Controls.Add(this.label1);
this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(624, 152);
this.panel1.TabIndex = 0;
//
// lvStudent
//
this.lvStudent.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.columnHeader1,
this.columnHeader2,
this.columnHeader3,
this.columnHeader4,
this.columnHeader5,
this.columnHeader6});
this.lvStudent.Dock = System.Windows.Forms.DockStyle.Fill;
this.lvStudent.GridLines = true;
this.lvStudent.LargeImageList = this.imageListMy;
this.lvStudent.Location = new System.Drawing.Point(152, 24);
this.lvStudent.Name = "lvStudent";
this.lvStudent.Size = new System.Drawing.Size(472, 128);
this.lvStudent.SmallImageList = this.imageListMy;
this.lvStudent.TabIndex = 3;
this.lvStudent.View = System.Windows.Forms.View.Details;
this.lvStudent.DoubleClick += new System.EventHandler(this.lvStudent_DoubleClick);
//
// columnHeader1
//
this.columnHeader1.Text = "姓名";
//
// columnHeader2
//
this.columnHeader2.Text = "學號";
//
// columnHeader3
//
this.columnHeader3.Text = "性別";
//
// columnHeader4
//
this.columnHeader4.Text = "出生年月";
//
// columnHeader5
//
this.columnHeader5.Text = "班級";
//
// columnHeader6
//
this.columnHeader6.Text = "備注";
//
// imageListMy
//
this.imageListMy.ImageSize = new System.Drawing.Size(16, 16);
this.imageListMy.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageListMy.ImageStream")));
this.imageListMy.TransparentColor = System.Drawing.Color.Transparent;
//
// tvClass
//
this.tvClass.Dock = System.Windows.Forms.DockStyle.Left;
this.tvClass.ImageList = this.imageListMy;
this.tvClass.Location = new System.Drawing.Point(0, 24);
this.tvClass.Name = "tvClass";
this.tvClass.Size = new System.Drawing.Size(152, 128);
this.tvClass.TabIndex = 2;
this.tvClass.DoubleClick += new System.EventHandler(this.tvClass_DoubleClick);
this.tvClass.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.tvClass_AfterSelect);
//
// label1
//
this.label1.BackColor = System.Drawing.SystemColors.ActiveCaption;
this.label1.Dock = System.Windows.Forms.DockStyle.Top;
this.label1.Font = new System.Drawing.Font("宋體", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.label1.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.label1.Location = new System.Drawing.Point(0, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(624, 24);
this.label1.TabIndex = 1;
this.label1.Text = "班級列表 學生信息";
//
// panel2
//
this.panel2.Controls.Add(this.dgScore);
this.panel2.Controls.Add(this.lvCourse);
this.panel2.Controls.Add(this.label2);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(0, 152);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(624, 197);
this.panel2.TabIndex = 1;
//
// dgScore
//
this.dgScore.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.dgScore.CaptionBackColor = System.Drawing.SystemColors.ActiveBorder;
this.dgScore.DataMember = "";
this.dgScore.Dock = System.Windows.Forms.DockStyle.Fill;
this.dgScore.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dgScore.Location = new System.Drawing.Point(160, 24);
this.dgScore.Name = "dgScore";
this.dgScore.Size = new System.Drawing.Size(464, 173);
this.dgScore.TabIndex = 4;
//
// lvCourse
//
this.lvCourse.Dock = System.Windows.Forms.DockStyle.Left;
this.lvCourse.LargeImageList = this.imageListMy;
this.lvCourse.Location = new System.Drawing.Point(0, 24);
this.lvCourse.Name = "lvCourse";
this.lvCourse.Size = new System.Drawing.Size(160, 173);
this.lvCourse.SmallImageList = this.imageListMy;
this.lvCourse.TabIndex = 3;
this.lvCourse.DoubleClick += new System.EventHandler(this.lvCourse_DoubleClick);
//
// label2
//
this.label2.BackColor = System.Drawing.SystemColors.ActiveCaption;
this.label2.Dock = System.Windows.Forms.DockStyle.Top;
this.label2.Font = new System.Drawing.Font("宋體", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.label2.Location = new System.Drawing.Point(0, 0);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(624, 24);
this.label2.TabIndex = 2;
this.label2.Text = "課程信息 成績信息";
//
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -