Beispiel #1
0
 private void btnApplyChanges_Click(object sender, EventArgs e)
 {
     if (radDark.Checked)
     {
         color = Color.FromArgb(41, 44, 51);
         Settings setting = new Settings();
         Form1    home    = new Form1();
         home.BackColor    = color;
         setting.BackColor = color;
         setting.Show();
     }
     if (radLight.Checked)
     {
         color = Color.WhiteSmoke;
         Settings setting = new Settings();
         setting.BackColor = color;
         setting.Show();
     }
 }
Beispiel #2
0
        private void button5_Click(object sender, EventArgs e)
        {
            string query = "SELECT eid FROM employee, type_table WHERE eid = " + eid +
                           " AND employee.employee_type = type_table.id AND type='Admin'";

            command = new OracleCommand(query, connection);
            connection.Open();
            reader = command.ExecuteReader();
            if (reader.HasRows)
            {
                connection.Close();
                Settings s = new Settings();
                s.Show();
            }
            else
            {
                connection.Close();
                MessageBox.Show("Please login as administrator to access this module");
            }
            connection.Close();
        }
Beispiel #3
0
 public void ShowSettingsDialog()
 {
     Settings form = new Settings();
     form.FormClosed += form_FormClosed;
     form.Show();
 }