📄 frmviewresult.cs
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
namespace OES
{
/// <summary>
/// Summary description for Form1.
/// </summary>
public class frmViewResult : System.Windows.Forms.Form
{
private System.Windows.Forms.DateTimePicker dtpFrom;
private System.Windows.Forms.DateTimePicker dtpTo;
private System.Windows.Forms.Label lblFrom;
private System.Windows.Forms.Label lblTo;
private System.Windows.Forms.Button btnPrint;
private System.Windows.Forms.Button btnHelp;
private System.Windows.Forms.Button btnClose;
private System.Windows.Forms.ComboBox cboSubject;
private System.Windows.Forms.Label lblSubject;
private System.Windows.Forms.Button btnSearch;
private System.Windows.Forms.Label label1;
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.Container components = null;
string []searchvalue;
private System.Windows.Forms.DataGrid dbgStudent;
private System.Drawing.Printing.PrintDocument pDoc;
private System.Windows.Forms.PrintDialog pdlgStudent;
private System.Windows.Forms.PrintPreviewDialog ppdlgStudent;
private System.Windows.Forms.Button button1;
Exam objExam;
public frmViewResult()
{
//
// Required for Windows Form Designer support
//
InitializeComponent();
searchvalue =new string[4];
objExam = new Exam();
//
// TODO: Add any constructor code after InitializeComponent call
//
}
/// <summary>
/// Clean up any resources being used.
/// </summary>
protected override void Dispose( bool disposing )
{
if( disposing )
{
if (components != null)
{
components.Dispose();
}
}
base.Dispose( disposing );
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(frmViewResult));
this.cboSubject = new System.Windows.Forms.ComboBox();
this.dtpFrom = new System.Windows.Forms.DateTimePicker();
this.dtpTo = new System.Windows.Forms.DateTimePicker();
this.lblFrom = new System.Windows.Forms.Label();
this.lblTo = new System.Windows.Forms.Label();
this.lblSubject = new System.Windows.Forms.Label();
this.btnPrint = new System.Windows.Forms.Button();
this.btnClose = new System.Windows.Forms.Button();
this.btnHelp = new System.Windows.Forms.Button();
this.btnSearch = new System.Windows.Forms.Button();
this.dbgStudent = new System.Windows.Forms.DataGrid();
this.label1 = new System.Windows.Forms.Label();
this.pDoc = new System.Drawing.Printing.PrintDocument();
this.pdlgStudent = new System.Windows.Forms.PrintDialog();
this.ppdlgStudent = new System.Windows.Forms.PrintPreviewDialog();
this.button1 = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.dbgStudent)).BeginInit();
this.SuspendLayout();
//
// cboSubject
//
this.cboSubject.BackColor = System.Drawing.SystemColors.Info;
this.cboSubject.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cboSubject.Location = new System.Drawing.Point(448, 112);
this.cboSubject.Name = "cboSubject";
this.cboSubject.Size = new System.Drawing.Size(112, 23);
this.cboSubject.TabIndex = 0;
//
// dtpFrom
//
this.dtpFrom.CustomFormat = "dd\'/\'MM\'/\'yyyy";
this.dtpFrom.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.dtpFrom.Location = new System.Drawing.Point(176, 112);
this.dtpFrom.Name = "dtpFrom";
this.dtpFrom.Size = new System.Drawing.Size(80, 21);
this.dtpFrom.TabIndex = 1;
this.dtpFrom.Value = new System.DateTime(2004, 12, 7, 0, 0, 0, 0);
//
// dtpTo
//
this.dtpTo.CustomFormat = "dd\'/\'MM\'/\'yyyy";
this.dtpTo.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.dtpTo.Location = new System.Drawing.Point(296, 112);
this.dtpTo.Name = "dtpTo";
this.dtpTo.Size = new System.Drawing.Size(80, 21);
this.dtpTo.TabIndex = 2;
//
// lblFrom
//
this.lblFrom.AutoSize = true;
this.lblFrom.BackColor = System.Drawing.Color.Transparent;
this.lblFrom.Font = new System.Drawing.Font("Century Gothic", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
this.lblFrom.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.lblFrom.Location = new System.Drawing.Point(136, 112);
this.lblFrom.Name = "lblFrom";
this.lblFrom.Size = new System.Drawing.Size(18, 18);
this.lblFrom.TabIndex = 3;
this.lblFrom.Text = "自";
this.lblFrom.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
//
// lblTo
//
this.lblTo.AutoSize = true;
this.lblTo.BackColor = System.Drawing.Color.Transparent;
this.lblTo.Font = new System.Drawing.Font("Century Gothic", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
this.lblTo.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.lblTo.Location = new System.Drawing.Point(264, 112);
this.lblTo.Name = "lblTo";
this.lblTo.Size = new System.Drawing.Size(18, 18);
this.lblTo.TabIndex = 4;
this.lblTo.Text = "至";
this.lblTo.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
//
// lblSubject
//
this.lblSubject.AutoSize = true;
this.lblSubject.BackColor = System.Drawing.Color.Transparent;
this.lblSubject.Font = new System.Drawing.Font("Century Gothic", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
this.lblSubject.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.lblSubject.Location = new System.Drawing.Point(392, 112);
this.lblSubject.Name = "lblSubject";
this.lblSubject.Size = new System.Drawing.Size(32, 18);
this.lblSubject.TabIndex = 5;
this.lblSubject.Text = "科目";
this.lblSubject.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
//
// btnPrint
//
this.btnPrint.BackColor = System.Drawing.Color.Transparent;
this.btnPrint.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.btnPrint.Font = new System.Drawing.Font("Verdana", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
this.btnPrint.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.btnPrint.Location = new System.Drawing.Point(216, 392);
this.btnPrint.Name = "btnPrint";
this.btnPrint.Size = new System.Drawing.Size(80, 24);
this.btnPrint.TabIndex = 7;
this.btnPrint.Text = "打印(&P)";
this.btnPrint.Click += new System.EventHandler(this.btnPrint_Click);
//
// btnClose
//
this.btnClose.BackColor = System.Drawing.Color.Transparent;
this.btnClose.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.btnClose.Font = new System.Drawing.Font("Verdana", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
this.btnClose.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.btnClose.Location = new System.Drawing.Point(432, 392);
this.btnClose.Name = "btnClose";
this.btnClose.Size = new System.Drawing.Size(80, 24);
this.btnClose.TabIndex = 9;
this.btnClose.Text = "关闭(&O)";
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
//
// btnHelp
//
this.btnHelp.BackColor = System.Drawing.Color.Transparent;
this.btnHelp.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.btnHelp.Font = new System.Drawing.Font("Verdana", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
this.btnHelp.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.btnHelp.Location = new System.Drawing.Point(568, 15);
this.btnHelp.Name = "btnHelp";
this.btnHelp.Size = new System.Drawing.Size(72, 24);
this.btnHelp.TabIndex = 10;
this.btnHelp.Text = "帮助(&H)";
this.btnHelp.Click += new System.EventHandler(this.btnHelp_Click);
//
// btnSearch
//
this.btnSearch.BackColor = System.Drawing.Color.Transparent;
this.btnSearch.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
this.btnSearch.Font = new System.Drawing.Font("Verdana", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
this.btnSearch.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
this.btnSearch.Location = new System.Drawing.Point(568, 112);
this.btnSearch.Name = "btnSearch";
this.btnSearch.Size = new System.Drawing.Size(72, 24);
this.btnSearch.TabIndex = 11;
this.btnSearch.Text = "搜索(&S)";
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -