Exemple #1
0
        public SearchCourseForm()
        {
            InitializeComponent();
            this.dataSet = new DataSet();

            Config config = new Config();

            this.operationDB = new OperationDB(config.dbStr);
            this.operationDB.Open();
        }
        public ModifyForm(DataSet data)
        {
            InitializeComponent();
            dataSet = data;
            this.dataGridViewRecord.DataSource = dataSet.Tables[0];

            Config config = new Config();

            this.operationDB = new OperationDB(config.dbStr);
            this.operationDB.Open();
        }
        public UpdateCourseForm()
        {
            InitializeComponent();
            InitDataSet();
            this.dataGridViewRecord.DataSource = this.dataSet.Tables[0];

            Config config = new Config();

            this.operationDB = new OperationDB(config.dbStr);
            this.operationDB.Open();
        }
Exemple #4
0
        public InputForm()
        {
            InitializeComponent();
            InitDataSet();
            this.dataGridViewRecord.DataSource = this.dataSet.Tables[0];

            Config config = new Config();

            this.operationDB = new OperationDB(config.dbStr);
            this.operationDB.Open();

            this._mapMajor  = new Dictionary <string, string>();
            this.mapMajor   = this.operationDB.GetMapIdName("name", "id", "major");
            this._mapCource = new Dictionary <string, string>();
            this.mapCource  = this.operationDB.GetMapIdName("name", "credit", "course");
        }