Esempio n. 1
0
        private void FixedBug_Load(object sender, EventArgs e)
        {
            string type = login.loggedIN_utype;

            if (type == "Admin")
            {
                //creating datatable to hold the categories from database
                FixedBug  a        = new FixedBug();
                DataTable dtassign = a.Select_bugtitle();
                //specify datasource for assigned box
                comboBox1.DataSource = dtassign;
                //specify display member and valuemenber for combobox
                comboBox1.DisplayMember = "bugtitle";
                comboBox1.ValueMember   = "bugtitle";
            }
            else
            {
                //creating datatable to hold the categories from database
                FixedBug  a        = new FixedBug();
                DataTable dtassign = a.Select_debugtitle();
                //specify datasource for assigned box
                comboBox1.DataSource = dtassign;
                //specify display member and valuemenber for combobox
                comboBox1.DisplayMember = "bugtitle";
                comboBox1.ValueMember   = "bugtitle";
            }
        }
Esempio n. 2
0
        private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            string    title = comboBox1.Text;
            FixedBug  vu    = new FixedBug();
            DataTable dt    = vu.Sort_bugtitle(title);

            dgv_fixed.DataSource = dt;
        }
        private void button4_Click(object sender, EventArgs e)
        {
            FixedBug fb = new FixedBug();

            fb.Show();
        }