Разработка системы учета оплаты обучения студентами
Курсовой проект - Компьютеры, программирование
Другие курсовые по предмету Компьютеры, программирование
MenuItem();.menuItem6 = new System.Windows.Forms.MenuItem();.menuItem7 = new System.Windows.Forms.MenuItem();.menuItem8 = new System.Windows.Forms.MenuItem();.menuItem9 = new System.Windows.Forms.MenuItem();.menuItem10 = new System.Windows.Forms.MenuItem();.menuItem11 = new System.Windows.Forms.MenuItem();.menuItem12 = new System.Windows.Forms.MenuItem();.menuItem5 = new System.Windows.Forms.MenuItem();.menuItem2 = new System.Windows.Forms.MenuItem();.menuItem1 = new System.Windows.Forms.MenuItem();.menuItem3 = new System.Windows.Forms.MenuItem();.SuspendLayout();
//
// ImageButton1
// .ImageButton1.AccessibleName = "Редактировать оплаты";.ImageButton1.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;.ImageButton1.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("znOFFImageButton1.BackgroundImage")));.ImageButton1.Cursor = System.Windows.Forms.Cursors.Hand;.ImageButton1.Font = new System.Drawing.Font("Verdana", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(204)));.ImageButton1.Location = new System.Drawing.Point(96, 248);.ImageButton1.Name = "znOFFImageButton1";.ImageButton1.Size = new System.Drawing.Size(150, 50);.ImageButton1.TabIndex = 0;.ImageButton1.MouseUp += new System.Windows.Forms.MouseEventHandler(this.znOFFImageButton1_MouseUp);
//
// ImageButton2
// .ImageButton2.AccessibleName = "Создать отчёт";.ImageButton2.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;.ImageButton2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));.ImageButton2.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("znOFFImageButton2.BackgroundImage")));.ImageButton2.Cursor = System.Windows.Forms.Cursors.Hand;.ImageButton2.Font = new System.Drawing.Font("Verdana", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(204)));.ImageButton2.Location = new System.Drawing.Point(450, 250);.ImageButton2.Name = "znOFFImageButton2";.ImageButton2.Size = new System.Drawing.Size(150, 50);.ImageButton2.TabIndex = 0;.ImageButton2.MouseUp += new System.Windows.Forms.MouseEventHandler(this.znOFFImageButton2_MouseUp);
//
// pictureBox1
// .pictureBox1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;.pictureBox1.Image = ((System.Drawing.Image)(resources.GetObject("pictureBox1.Image")));.pictureBox1.Location = new System.Drawing.Point(32, 24);.pictureBox1.Name = "pictureBox1";.pictureBox1.Size = new System.Drawing.Size(288, 216);.pictureBox1.TabIndex = 1;.pictureBox1.TabStop = false;
//
// pictureBox2
// .pictureBox2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));.pictureBox2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;.pictureBox2.Image = ((System.Drawing.Image)(resources.GetObject("pictureBox2.Image")));.pictureBox2.Location = new System.Drawing.Point(384, 24);.pictureBox2.Name = "pictureBox2";.pictureBox2.Size = new System.Drawing.Size(288, 216);.pictureBox2.TabIndex = 2;.pictureBox2.TabStop = false;
//
// mainMenu1
// .mainMenu1.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {.menuItem4,.menuItem2});
//
// menuItem4
// .menuItem4.Index = 0;.menuItem4.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {.menuItem6,.menuItem5});.menuItem4.Text = "База данных";
//
// menuItem6
// .menuItem6.Index = 0;.menuItem6.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {.menuItem7,.menuItem8,.menuItem9,.menuItem10,.menuItem11,.menuItem12});.menuItem6.Text = "Редактировать";
//
// menuItem7
// .menuItem7.Index = 0;.menuItem7.Text = "Таблица студентов";.menuItem7.Click += new System.EventHandler(this.menuItem7_Click);
//
// menuItem8
// .menuItem8.Index = 1;.menuItem8.Text = "Таблица дисциплин";.menuItem8.Click += new System.EventHandler(this.menuItem8_Click);
//
// menuItem9
// .menuItem9.Index = 2;.menuItem9.Text = "Таблица групп";.menuItem9.Click += new System.EventHandler(this.menuItem9_Click);
//
// menuItem10
// .menuItem10.Index = 3;.menuItem10.Text = "Таблица причин оплаты";.menuItem10.Click += new System.EventHandler(this.menuItem10_Click);
//
// menuItem11
// .menuItem11.Index = 4;.menuItem11.Text = "Таблица форм обучения";.menuItem11.Click += new System.EventHandler(this.menuItem11_Click);
//
// menuItem12
// .menuItem12.Index = 5;.menuItem12.Text = "Таблица форм оплаты";.menuItem12.Click += new System.EventHandler(this.menuItem12_Click);
//
// menuItem5
// .menuItem5.Index = 1;.menuItem5.Text = "Изменить текущую БД";.menuItem5.Click += new System.EventHandler(this.menuItem5_Click);
//
// menuItem2
// .menuItem2.Index = 1;.menuItem2.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {.menuItem1,.menuItem3});.menuItem2.Text = "Справка";
//
// menuItem1
// .menuItem1.Index = 0;.menuItem1.Text = "Помощь";.menuItem1.Click += new System.EventHandler(this.menuItem1_Click);
//
// menuItem3
// .menuItem3.Index = 1;.menuItem3.Text = "О программе";.menuItem3.Click += new System.EventHandler(this.menuItem3_Click);
//
// Form1
// .AutoScaleBaseSize = new System.Drawing.Size(5, 13);.BackColor = System.Drawing.SystemColors.Control;.ClientSize = new System.Drawing.Size(706, 320);.Controls.Add(this.pictureBox2);.Controls.Add(this.pictureBox1);.Controls.Add(this.znOFFImageButton1);.Controls.Add(this.znOFFImageButton2);.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;.Menu = this.mainMenu1;.Name = "Form1";.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "Система учёта оплаты";
this.Load += new System.EventHandler(this.Form1_Load);.Paint += new System.Windows.Forms.PaintEventHandler(this.Form1_Paint);.ResumeLayout(false);
}
#endregion
///
/// The main entry point for the application.
///
[STAThread]void Main()
{.Run(new Form1());
}
static string строкаПодключения=@"Integrated Security=SSPI;User ID=Администратор;Data Source=""HOME"";Initial Catalog=OplataDB;Provider=""SQLOLEDB.1"";Workstation ID=""HOME"";Packet Size=4096";
void Form1_Load(object sender, System.EventArgs e)
{
{.IO.FileStream fs=new System.IO.FileStream("options.bak",System.IO.FileMode.Open);.IO.StreamReader reader=new System.IO.StreamReader(fs,System.Text.Encoding.UTF8);.строкаПодключения=reader.ReadLine();.Close();.Close();
}
{.ShowMyMessage("Ошибка при загрузке настроек.");
}
}
void Form1_Paint(object sender, System.Windows.Forms.PaintEventArgs e)
{g=this.CreateGraphics();LGB=new System.Drawing.Drawing2D.LinearGradientBrush(new Rectangle(0,0,this.Width,this.Height),Color.Black,Color.Teal,-45);.FillRectangle(LGB,0,0,this.Width,this.Height);.Dispose();
}
void znOFFImageButton1_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
{f2=new Form2();.ShowDialog();.Dispose();
}
void znOFFImageButton2_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
{f4=new Form4();.ShowDialog();.Dispose();
}
static void ShowMyMessage(string str)
{
Сообщение mes=new Сообщение();.label1.Text=str;.ShowDialog();.Dispose();
}
static bool Ответ(string str)
{
Вопрос v=new Вопрос();.label1.Text=str;.ShowDialog();v.ОтветДа;
}
void menuItem5_Click(object sender, System.EventArgs e)
{fo=new FormOptions();.ShowDialog();.Dispose();
}
void menuItem7_Click(object sender, System.EventArgs e)
{fed=new FormEditor();.таблица="Student";.ShowDialog();
}
void menuItem8_Click(object sender, System.EventArgs e)
{fed=new FormEditor();.таблица="Disciplina";.ShowDialog();
}
void menuItem9_Click(object sender, System.EventArgs e)
{fed=new FormEditor();.таблица="Gruppa";.ShowDialog();
}
void menuItem10_Click(object sender, System.EventArgs e)
{fed=new FormEditor();.таблица="Prichina";.ShowDialog();
}
void menuItem11_Click(object sender, System.EventArgs e)
{fed=new FormEditor();.таблица="FormaObuchenie";.ShowDialog();
}
void menuItem12_Click(object sender, System.EventArgs e)
{fed=new FormEditor();.таблица="FormaOplata";.ShowDialog();
}
private void menuItem3_Click(object sender, System.EventArgs e)
{.ShowMyMessage("Система учёта оплаты