DataSet dsClass=new DataSet();
DataTable dtClass=new DataTable("Class");
DataColumn id=new DataColumn("id",typeof(int));
DataColumn className=new DataColumn("className",typeof(string));
DataColumn gradeID=new DataColumn("gradeID",typeof(int));
dtClass.Columns.Add(id);
dtClass.Columns.Add(className);
dtClass.Columns.Add(gradeID); DataRow drClass=dtClass.NewRow();
drClass["className"]=this.txtClass.Text.Trim();
drClass["gradeID"]=gradeManager.GetGradeIDByGradeName(this.cboGrade.Text.Trim());
dtClass.Rows.Add(drClass);
dsClass.Tables.Add(dtClass);
DataSet dsClass=new DataSet();
DataTable dtClass=new DataTable("Class");
DataColumn id=new DataColumn("id",typeof(int));
DataColumn className=new DataColumn("className",typeof(string));
DataColumn gradeID=new DataColumn("gradeID",typeof(int));
dtClass.Columns.Add(id);
dtClass.Columns.Add(className);
dtClass.Columns.Add(gradeID); DataRow drClass=dtClass.NewRow();
drClass["className"]=this.txtClass.Text.Trim();
drClass["gradeID"]=gradeManager.GetGradeIDByGradeName(this.cboGrade.Text.Trim());
dtClass.Rows.Add(drClass);
dsClass.Tables.Add(dtClass);