diff --git a/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/App.config b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/App.config new file mode 100644 index 0000000..fad249e --- /dev/null +++ b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.Designer.cs b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.Designer.cs new file mode 100644 index 0000000..9a9a03e --- /dev/null +++ b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.Designer.cs @@ -0,0 +1,194 @@ +namespace WindowsFormsApplication2 +{ + partial class Form1 + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.label1 = new System.Windows.Forms.Label(); + this.label2 = new System.Windows.Forms.Label(); + this.textBox1 = new System.Windows.Forms.TextBox(); + this.textBox2 = new System.Windows.Forms.TextBox(); + this.comboBox2 = new System.Windows.Forms.ComboBox(); + this.radioButton1 = new System.Windows.Forms.RadioButton(); + this.label3 = new System.Windows.Forms.Label(); + this.monthCalendar1 = new System.Windows.Forms.MonthCalendar(); + this.label4 = new System.Windows.Forms.Label(); + this.button1 = new System.Windows.Forms.Button(); + this.label5 = new System.Windows.Forms.Label(); + this.SuspendLayout(); + // + // label1 + // + this.label1.AutoSize = true; + this.label1.Font = new System.Drawing.Font("Century", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label1.Location = new System.Drawing.Point(38, 32); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(135, 20); + this.label1.TabIndex = 0; + this.label1.Text = "Enter your name"; + // + // label2 + // + this.label2.AutoSize = true; + this.label2.Font = new System.Drawing.Font("Century", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label2.Location = new System.Drawing.Point(38, 92); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(166, 20); + this.label2.TabIndex = 1; + this.label2.Text = "Registration Number"; + // + // textBox1 + // + this.textBox1.Location = new System.Drawing.Point(42, 56); + this.textBox1.Name = "textBox1"; + this.textBox1.Size = new System.Drawing.Size(181, 20); + this.textBox1.TabIndex = 2; + this.textBox1.TextChanged += new System.EventHandler(this.textBox1_TextChanged); + // + // textBox2 + // + this.textBox2.Location = new System.Drawing.Point(42, 115); + this.textBox2.Name = "textBox2"; + this.textBox2.Size = new System.Drawing.Size(181, 20); + this.textBox2.TabIndex = 3; + this.textBox2.TextChanged += new System.EventHandler(this.textBox2_TextChanged); + // + // comboBox2 + // + this.comboBox2.FormattingEnabled = true; + this.comboBox2.Items.AddRange(new object[] { + "BSc Physics", + "BSc Chemistry", + "BSc Math", + "BTech CSE", + "BTech CSE-AIML", + "BTech CCE", + "BTech IT"}); + this.comboBox2.Location = new System.Drawing.Point(42, 216); + this.comboBox2.Name = "comboBox2"; + this.comboBox2.Size = new System.Drawing.Size(121, 21); + this.comboBox2.TabIndex = 5; + this.comboBox2.SelectedIndexChanged += new System.EventHandler(this.comboBox2_SelectedIndexChanged); + // + // radioButton1 + // + this.radioButton1.AutoSize = true; + this.radioButton1.Location = new System.Drawing.Point(242, 159); + this.radioButton1.Name = "radioButton1"; + this.radioButton1.Size = new System.Drawing.Size(43, 17); + this.radioButton1.TabIndex = 6; + this.radioButton1.TabStop = true; + this.radioButton1.Text = "Yes"; + this.radioButton1.UseVisualStyleBackColor = true; + this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged); + // + // label3 + // + this.label3.AutoSize = true; + this.label3.Font = new System.Drawing.Font("Century", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label3.Location = new System.Drawing.Point(38, 156); + this.label3.Name = "label3"; + this.label3.Size = new System.Drawing.Size(198, 20); + this.label3.TabIndex = 7; + this.label3.Text = "Sports/Music Experience?"; + // + // monthCalendar1 + // + this.monthCalendar1.Location = new System.Drawing.Point(42, 282); + this.monthCalendar1.Name = "monthCalendar1"; + this.monthCalendar1.TabIndex = 8; + this.monthCalendar1.DateChanged += new System.Windows.Forms.DateRangeEventHandler(this.monthCalendar1_DateChanged); + // + // label4 + // + this.label4.AutoSize = true; + this.label4.Font = new System.Drawing.Font("Century", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label4.Location = new System.Drawing.Point(38, 253); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(105, 20); + this.label4.TabIndex = 9; + this.label4.Text = "Date of Birth"; + // + // button1 + // + this.button1.Location = new System.Drawing.Point(42, 476); + this.button1.Name = "button1"; + this.button1.Size = new System.Drawing.Size(75, 23); + this.button1.TabIndex = 10; + this.button1.Text = "Submit"; + this.button1.UseVisualStyleBackColor = true; + this.button1.Click += new System.EventHandler(this.button1_Click); + // + // label5 + // + this.label5.AutoSize = true; + this.label5.Font = new System.Drawing.Font("Century", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label5.Location = new System.Drawing.Point(38, 193); + this.label5.Name = "label5"; + this.label5.Size = new System.Drawing.Size(118, 20); + this.label5.TabIndex = 11; + this.label5.Text = "Choose Degree"; + // + // Form1 + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(404, 580); + this.Controls.Add(this.label5); + this.Controls.Add(this.button1); + this.Controls.Add(this.label4); + this.Controls.Add(this.monthCalendar1); + this.Controls.Add(this.label3); + this.Controls.Add(this.radioButton1); + this.Controls.Add(this.comboBox2); + this.Controls.Add(this.textBox2); + this.Controls.Add(this.textBox1); + this.Controls.Add(this.label2); + this.Controls.Add(this.label1); + this.Name = "Form1"; + this.Text = "Form1"; + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private System.Windows.Forms.Label label1; + private System.Windows.Forms.Label label2; + private System.Windows.Forms.TextBox textBox1; + private System.Windows.Forms.TextBox textBox2; + private System.Windows.Forms.ComboBox comboBox2; + private System.Windows.Forms.RadioButton radioButton1; + private System.Windows.Forms.Label label3; + private System.Windows.Forms.MonthCalendar monthCalendar1; + private System.Windows.Forms.Label label4; + private System.Windows.Forms.Button button1; + private System.Windows.Forms.Label label5; + } +} + diff --git a/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.cs b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.cs new file mode 100644 index 0000000..94d58c0 --- /dev/null +++ b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.cs @@ -0,0 +1,50 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace WindowsFormsApplication2 +{ + public partial class Form1 : Form + { + public Form1() + { + InitializeComponent(); + } + + private void comboBox2_SelectedIndexChanged(object sender, EventArgs e) + { + label5.Text = "Chosen Degree: " + comboBox2.SelectedItem.ToString(); + } + + private void button1_Click(object sender, EventArgs e) + { + MessageBox.Show("Thank you for registering"); + } + + private void monthCalendar1_DateChanged(object sender, DateRangeEventArgs e) + { + label4.Text = "Date of Birth: " + e.Start.ToString("d"); // Sets the label text to the selected date in short format + } + + private void radioButton1_CheckedChanged(object sender, EventArgs e) + { + label3.Text = "Sports/Music Experience!"; + } + + private void textBox2_TextChanged(object sender, EventArgs e) + { + label2.Text = "Registration Number " + textBox2.Text; + } + + private void textBox1_TextChanged(object sender, EventArgs e) + { + label1.Text = "Your name is " + textBox1.Text; + } + } +} diff --git a/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.resx b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.resx new file mode 100644 index 0000000..29dcb1b --- /dev/null +++ b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/Form1.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/WindowsFormsApplication2.csproj b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/WindowsFormsApplication2.csproj new file mode 100644 index 0000000..5e18afc --- /dev/null +++ b/DBMS/C-Sharp/Lab/Week1/Register/WindowsFormsApplication2/WindowsFormsApplication2.csproj @@ -0,0 +1,88 @@ + + + + + Debug + AnyCPU + {59A6EC54-1044-40A7-B6E4-551F02FC543D} + WinExe + Properties + WindowsFormsApplication2 + WindowsFormsApplication2 + v4.5 + 512 + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + + Form + + + Form1.cs + + + + + Form1.cs + + + ResXFileCodeGenerator + Resources.Designer.cs + Designer + + + True + Resources.resx + + + SettingsSingleFileGenerator + Settings.Designer.cs + + + True + Settings.settings + True + + + + + + + + \ No newline at end of file