private static bool CheckIfDuplicateQ(string qst, string ans1, string ans2, string ans3, string ans4)
        {
            QuestionStackManipulation qstCheckDuplicatetDB = new QuestionStackManipulation();

            return(false);
            //throw new NotImplementedException();
        }
        private static void InsertQintoDB(string qst, string ans1, string ans2, string ans3, string ans4, int cor, string exp, int cat1, int subcat1, string com)
        {
            QuestionStackManipulation qstInsertDB = new QuestionStackManipulation();

            //
            CheckIfDuplicateQ(qst, ans1, ans2, ans3, ans4);
            //throw new NotImplementedException();
        }
예제 #3
0
        public void SetCategoriesInCombo()
        {
            QuestionStackManipulation sc = new QuestionStackManipulation();

            QCategory_comboBox.DataSource    = new BindingSource(sc.CategoryFromDB(), null);
            QCategory_comboBox.DisplayMember = "Value";
            QCategory_comboBox.ValueMember   = "Key";
        }
예제 #4
0
        public void Subcategory_Fill()
        {
            QuestionStackManipulation sc = new QuestionStackManipulation();

            QSubcategory_comboBox.DataSource    = new BindingSource(sc.SubcategoryFromDB(CategoryID), null);
            QSubcategory_comboBox.DisplayMember = "Value";
            QSubcategory_comboBox.ValueMember   = "Key";
        }
        private void CategoryChange_Selection(object sender, EventArgs e)
        {
            QuestionStackManipulation sc = new QuestionStackManipulation();

            CategoryID = ((KeyValuePair <string, string>)Category_comboBox.SelectedItem).Key;

            Subcategory_Fill();
        }
예제 #6
0
        private void CategoryChange_Selection(object sender, EventArgs e)
        {
            QuestionStackManipulation sc = new QuestionStackManipulation();

            CategoryID = ((KeyValuePair <string, string>)QCategory_comboBox.SelectedItem).Key;
            Subcategory_Fill();

            if (CategoryID == "0" || CategoryID == "")
            {
                CategSelect = "";
            }
            else
            {
                CategSelect = " and (CategoryID=" + CategoryID + " or AdditionalCategoryID=" + CategoryID + ") ";
            }
        }