public static StringBuilder DDLProgram(string _idSelect, string _degreeLevelId, string _facultyId) { Dictionary<string, object> _loginResult = SCHUtil.GetInfoLogin("", ""); Dictionary<string, object> _paramSearch = new Dictionary<string, object>(); StringBuilder _str = new StringBuilder(); string _username = _loginResult["Username"].ToString(); string _systemGroup = _loginResult["SystemGroup"].ToString(); string _userprogram = _loginResult["Userprogram"].ToString(); int _i = 0; _paramSearch.Clear(); _paramSearch.Add("DegreeLevelId", _degreeLevelId); _paramSearch.Add("FacultyId", _facultyId); _paramSearch.Add("ProgramId", _userprogram); DataSet _ds = SCHDB.GetListProgram(_username, _systemGroup, _paramSearch); string[] _optionValue = new string[_ds.Tables[0].Rows.Count]; string[] _optionTextTH = new string[_ds.Tables[0].Rows.Count]; string[] _optionTextEN = new string[_ds.Tables[0].Rows.Count]; foreach (DataRow _dr in _ds.Tables[0].Rows) { _optionValue[_i] = _dr["programId"].ToString(); _optionTextTH[_i] = ((_dr["programCode"].ToString() + " " + _dr["majorCode"].ToString() + " " + _dr["groupNum"].ToString()) + " : " + _dr["programNameTH"].ToString()); _optionTextEN[_i] = ((_dr["programCode"].ToString() + " " + _dr["majorCode"].ToString() + " " + _dr["groupNum"].ToString()) + " : " + _dr["programNameEN"].ToString()); _i++; } _ds.Dispose(); return GetSelect(_idSelect, "เลือก", "Select", _optionValue, _optionTextTH, _optionTextEN); }
public static Dictionary <string, object> GetSearch(Dictionary <string, object> _paramSearch) { Dictionary <string, object> _loginResult = SCHUtil.GetInfoLogin("", ""); Dictionary <string, object> _searchResult = new Dictionary <string, object>(); DataSet _ds = new DataSet(); DataRow[] _dr = null; string _username = _loginResult["Username"].ToString(); string _userlevel = _loginResult["Userlevel"].ToString(); string _systemGroup = _loginResult["SystemGroup"].ToString(); int _recordCount = 0; int _recordCountPrimary = 0; StringBuilder _list = new StringBuilder(); StringBuilder _navPage = new StringBuilder(); _ds = SCHDB.GetListStudent(_username, _userlevel, _systemGroup, _paramSearch); _dr = _ds.Tables[0].Select("rowNum >= " + _paramSearch["StartRow"] + " AND rowNum <= " + _paramSearch["EndRow"]); _recordCount = _ds.Tables[0].Rows.Count; _recordCountPrimary = _ds.Tables[0].Rows.Count; _list = SCHRegisterScholarshipUI.ListUI.GetMain(_dr); _navPage = SCHUtil.GetNavPage(_recordCount, (int)(_paramSearch["CurrentPage"]), SCHUtil.PAGE_REGISTERSCHOLARSHIP_MAIN, (int)(_paramSearch["RowPerPage"])); _ds.Dispose(); _searchResult.Add("RecordCount", _recordCount); _searchResult.Add("RecordCountPrimary", _recordCountPrimary); _searchResult.Add("Sum", 0); _searchResult.Add("List", _list); _searchResult.Add("NavPage", _navPage); return(_searchResult); }
public static StringBuilder DDLFaculty(string _idSelect) { Dictionary<string, object> _loginResult = SCHUtil.GetInfoLogin("", ""); Dictionary<string, object> _paramSearch = new Dictionary<string, object>(); StringBuilder _str = new StringBuilder(); string _username = _loginResult["Username"].ToString(); string _systemGroup = _loginResult["SystemGroup"].ToString(); string _userfaculty = _loginResult["Userfaculty"].ToString(); int _i = 0; _paramSearch.Add("FacultyId", _userfaculty); DataSet _ds = SCHDB.GetListFaculty(_username, _systemGroup, _paramSearch); DataRow[] _dr = _ds.Tables[0].Select("facultyId <> 'MU-01'"); string[] _optionValue = new string[_ds.Tables[0].Rows.Count]; string[] _optionTextTH = new string[_ds.Tables[0].Rows.Count]; string[] _optionTextEN = new string[_ds.Tables[0].Rows.Count]; foreach (DataRow _dr1 in _dr) { _optionValue[_i] = _dr1["facultyId"].ToString(); _optionTextTH[_i] = (_dr1["facultyCode"].ToString() + " : " + _dr1["facultyNameTH"].ToString()); _optionTextEN[_i] = (_dr1["facultyCode"].ToString() + " : " + _dr1["facultyNameEN"].ToString()); _i++; } _ds.Dispose(); return GetSelect(_idSelect, "เลือก", "Select", _optionValue, _optionTextTH, _optionTextEN); }
public static Dictionary <string, object> GetSearch(Dictionary <string, object> _paramSearch) { Dictionary <string, object> _loginResult = SCHUtil.GetInfoLogin("", ""); Dictionary <string, object> _searchResult = new Dictionary <string, object>(); DataSet _ds = new DataSet(); DataRow[] _dr = null; string _username = _loginResult["Username"].ToString(); string _userlevel = _loginResult["Userlevel"].ToString(); string _systemGroup = _loginResult["SystemGroup"].ToString(); int _recordCount = 0; int _recordCountPrimary = 0; object _sum = 0; StringBuilder _list = new StringBuilder(); StringBuilder _navPage = new StringBuilder(); _ds = SCHDB.GetListTranStudentFinanceScholarshipClassificationRecipient(_username, _userlevel, _systemGroup, _paramSearch); _dr = _ds.Tables[0].Select("rowNum >= " + _paramSearch["StartRow"] + " AND rowNum <= " + _paramSearch["EndRow"]); _recordCount = _ds.Tables[0].Rows.Count; _recordCountPrimary = _ds.Tables[0].Rows.Count; _sum = _ds.Tables[0].Compute("SUM(tuition)", ""); _list = SCHReportScholarshipUI.ListOfPeopleApprovedFinanceFromICLUI.ListUI.GetMain(_dr); _navPage = SCHUtil.GetNavPage(_recordCount, (int)(_paramSearch["CurrentPage"]), SCHUtil.PAGE_REPORTLISTOFPEOPLEAPPROVEDFINANCEFROMICL_MAIN, (int)(_paramSearch["RowPerPage"])); _ds.Dispose(); _searchResult.Add("RecordCount", _recordCount); _searchResult.Add("RecordCountPrimary", _recordCountPrimary); _searchResult.Add("Sum", (!String.IsNullOrEmpty(_sum.ToString()) ? _sum : 0)); _searchResult.Add("List", _list); _searchResult.Add("NavPage", _navPage); return(_searchResult); }
public static Dictionary <string, object> GetSearch(Dictionary <string, object> _paramSearch) { Dictionary <string, object> _loginResult = SCHUtil.GetInfoLogin("", ""); Dictionary <string, object> _searchResult = new Dictionary <string, object>(); DataSet _ds = new DataSet(); DataRow[] _dr = null; string _username = _loginResult["Username"].ToString(); string _userlevel = _loginResult["Userlevel"].ToString(); string _systemGroup = _loginResult["SystemGroup"].ToString(); int _recordCount = 0; int _recordCountPrimary = 0; object _sum = 0; StringBuilder _list = new StringBuilder(); _ds = SCHDB.GetListTranStudentFinanceScholarshipSavePeopleApproved(_username, _userlevel, _systemGroup, _paramSearch); _dr = _ds.Tables[0].Select(); _recordCount = _ds.Tables[0].Rows.Count; _recordCountPrimary = _ds.Tables[0].Rows.Count; _sum = _ds.Tables[0].Compute("SUM(tuition)", ""); _list = SCHFinanceScholarshipUI.ICLUI.SavePeopleApprovedUI.ListUI.GetMain(_dr); _ds.Dispose(); _searchResult.Add("RecordCount", _recordCount); _searchResult.Add("RecordCountPrimary", _recordCountPrimary); _searchResult.Add("Sum", (!String.IsNullOrEmpty(_sum.ToString()) ? _sum : 0)); _searchResult.Add("List", _list); _searchResult.Add("NavPage", new StringBuilder()); return(_searchResult); }
public static Dictionary <string, object> GetSearch(Dictionary <string, object> _paramSearch) { Dictionary <string, object> _loginResult = SCHUtil.GetInfoLogin("", ""); Dictionary <string, object> _searchResult = new Dictionary <string, object>(); DataSet _ds = new DataSet(); DataRow[] _dr = null; string _username = _loginResult["Username"].ToString(); string _userlevel = _loginResult["Userlevel"].ToString(); string _systemGroup = _loginResult["SystemGroup"].ToString(); string[] _scholarshipsTypeGroup = _paramSearch["ScholarshipsId"].ToString().Split(':'); int _recordCount = 0; int _recordCountPrimary = 0; StringBuilder _list = new StringBuilder(); StringBuilder _navPage = new StringBuilder(); _ds = SCHDB.GetListTranStudentManageScholarship(_username, _userlevel, _systemGroup, _paramSearch); _dr = _ds.Tables[0].Select("rowNum >= " + _paramSearch["StartRow"] + " AND rowNum <= " + _paramSearch["EndRow"]); _recordCount = _ds.Tables[0].Rows.Count; _recordCountPrimary = _ds.Tables[0].Rows.Count; if (_paramSearch["ScholarshipsTypeGroup"].Equals("")) { _list = SCHManageScholarshipUI.StudentCancelUI.ListUI.GetMain(_dr); } if (_paramSearch["ScholarshipsTypeGroup"].Equals(SCHUtil.SUBJECT_ICL)) { _list = SCHManageScholarshipUI.ICLUI.StudentCancelUI.ListUI.GetMain(_dr); } _navPage = SCHUtil.GetNavPage(_recordCount, (int)(_paramSearch["CurrentPage"]), SCHUtil.PAGE_MANAGESCHOLARSHIPSTUDENTCANCEL_MAIN, (int)(_paramSearch["RowPerPage"])); _ds.Dispose(); _searchResult.Add("RecordCount", _recordCount); _searchResult.Add("RecordCountPrimary", _recordCountPrimary); _searchResult.Add("Sum", 0); _searchResult.Add("List", _list); _searchResult.Add("NavPage", _navPage); return(_searchResult); }
public static StringBuilder GetUserProfile() { StringBuilder _str = new StringBuilder(); Dictionary<string, object> _loginResult = SCHUtil.GetInfoLogin(SCHUtil.PAGE_MAIN, ""); int _cookieError = int.Parse(_loginResult["CookieError"].ToString()); int _userError = int.Parse(_loginResult["UserError"].ToString()); string _userlevel = _loginResult["Userlevel"].ToString(); string _userfaculty = _loginResult["Userfaculty"].ToString(); string[] _fullNameTH = _loginResult["FullNameTH"].ToString().Split(' '); string _fullNameEN = _loginResult["FullNameEN"].ToString(); string _facultyColor = "#FFC726"; if (_cookieError.Equals(0) && _userError.Equals(0)) { _str.AppendLine("<div class='ui stackable secondary menu'>"); _str.AppendLine(" <div class='item'>"); _str.AppendFormat(" <input type='hidden' id='main-userfaculty-hidden' value='{0}'/>", _userfaculty); _str.AppendFormat(" <input type='hidden' id='main-currentyear-hidden' value='{0}'/>", SCHUtil._yearTH); _str.AppendLine(" <span class='f9 font-th regular black'><i class='user icon'></i></span>"); _str.AppendFormat(" <span class='lang lang-th f9 font-th regular black'>{0}</span>", (_fullNameTH[0] + " " + _fullNameTH[1])); _str.AppendFormat(" <span class='lang lang-en f9 font-en regular black'>{0}</span>", _fullNameEN); _str.AppendFormat(" <span class='lang-th f9 font-th regular' style='color:{1}'> ( {2} )</span>", _userfaculty.Substring(0, 2), _facultyColor, _userfaculty.Substring(0, 2)); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='right menu'>"); _str.AppendLine(" <div class='ui search'>"); _str.AppendLine(" <div class='ui icon input large hide' id='main-quicksearch'>"); _str.AppendLine(" <input id='main-keyword' type='text' placeholder='' placeholderth='คำค้น' placeholderen='keyword' />"); _str.AppendLine(" <i class='search link icon' id='main-btnquicksearch' ></i>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine("</div>"); } return _str; }
protected void Page_Load(object sender, EventArgs e) { string _action = Request.QueryString["action"]; string _page = String.Empty; string _fileName = String.Empty; string _saveFile = String.Empty; string _username = String.Empty; int _cookieError = 0; int _userError = 0; int _error = 0; Dictionary <string, object> _loginResult = new Dictionary <string, object>(); Dictionary <string, object> _uploadFileResult = new Dictionary <string, object>(); JavaScriptSerializer _json = new JavaScriptSerializer(); StringBuilder _mainContent = new StringBuilder(); if (_action.Equals(SCHUtil.SUBJECT_IMPORTREGISTERSCHOLARSHIP)) { _page = SCHUtil.PAGE_IMPORTREGISTERSCHOLARSHIP_MAIN; _fileName = (DateTime.Now).ToString("dd-MM-yyyy@HH-mm-ss", new CultureInfo("en-US")); } _loginResult = SCHUtil.GetInfoLogin(_page, ""); _cookieError = int.Parse(_loginResult["CookieError"].ToString()); _userError = int.Parse(_loginResult["UserError"].ToString()); _username = _loginResult["Username"].ToString(); //try //{ FileInfo _f = new FileInfo(Request.Files[0].FileName); _fileName = (_f.Name.Replace(_f.Extension, "") + _username.ToUpper() + _fileName); _saveFile = (Server.MapPath("~") + "/" + SCHUtil._myFileUploadPath + "/" + _fileName + _f.Extension.ToLower()); Request.Files[0].SaveAs(_saveFile); if (_page.Equals(SCHUtil.PAGE_IMPORTREGISTERSCHOLARSHIP_MAIN)) { DataSet _ds = SCHUtil.GetExcelToDataSet(_saveFile); _error = SCHUtil.ValidateDataExcel(_ds, SCHImportRegisterScholarshipUtil._excelFirstRow); _error = (_error.Equals(1) ? 3 : _error); _error = (_error.Equals(2) ? 4 : _error); _mainContent = (_error.Equals(0) ? SCHImportRegisterScholarshipUI.ListUI.GetMain(_loginResult, _ds.Tables[0].Select()) : null); _ds.Dispose(); } /* * } * catch * { * _error = 2; * } */ _uploadFileResult.Add("SignInYN", "Y"); _uploadFileResult.Add("CookieError", _cookieError.ToString()); _uploadFileResult.Add("UserError", _userError.ToString()); _uploadFileResult.Add("Username", _username); _uploadFileResult.Add("UploadFileError", _error.ToString()); _uploadFileResult.Add("MainContent", (_mainContent != null ? _mainContent.ToString() : String.Empty)); Response.Write(_json.Serialize(_uploadFileResult)); }
public static StringBuilder GetMain(string _id) { Dictionary <string, object> _loginResult = SCHUtil.GetInfoLogin("", ""); StringBuilder _str = new StringBuilder(); Dictionary <string, object> _paramSearch = new Dictionary <string, object>(); Dictionary <string, object> _valueDataRecorded = SCHUtil.SetValueDataRecorded(SCHUtil.PAGE_REGISTERSCHOLARSHIPSTUDENTCV_MAIN, _id, null); Dictionary <string, object> _dataRecorded = (_valueDataRecorded != null ? (Dictionary <string, object>)_valueDataRecorded["DataRecorded" + SCHUtil.SUBJECT_REGISTERSCHOLARSHIPSTUDENTCV] : null); string _username = _loginResult["Username"].ToString(); string _userlevel = _loginResult["Userlevel"].ToString(); string _systemGroup = _loginResult["SystemGroup"].ToString(); string _studentCode = _dataRecorded["StudentCode"].ToString(); string _fullNameTH = SCHUtil.GetFullName(_dataRecorded["TitleInitialsTH"].ToString(), _dataRecorded["TitleFullNameTH"].ToString(), _dataRecorded["FirstName"].ToString(), _dataRecorded["MiddleName"].ToString(), _dataRecorded["LastName"].ToString()); string _fullNameEN = SCHUtil.GetFullName(_dataRecorded["TitleInitialsEN"].ToString(), _dataRecorded["TitleFullNameEN"].ToString(), _dataRecorded["FirstNameEN"].ToString(), _dataRecorded["MiddleNameEN"].ToString(), _dataRecorded["LastNameEN"].ToString()).ToUpper(); string _facultyNameTH = _dataRecorded["FacultyNameTH"].ToString(); string _facultyNameEN = _dataRecorded["FacultyNameEN"].ToString(); string _programNameTH = _dataRecorded["ProgramNameTH"].ToString(); string _programNameEN = _dataRecorded["ProgramNameEN"].ToString(); string _statusTypeNameTH = _dataRecorded["StatusTypeNameTH"].ToString(); string _statusTypeNameEN = _dataRecorded["StatusTypeNameEN"].ToString(); string _row = String.Empty; string _scholarshipsNameTH = String.Empty; string _scholarshipsNameEN = String.Empty; string _responsibleAgency = String.Empty; string _registerDate = String.Empty; string _scholarshipsYear = String.Empty; string _semester = String.Empty; _str.AppendLine(GetValue(_valueDataRecorded).ToString()); _str.AppendLine("<div class='ui form'>"); _str.AppendLine(" <div class='ui right aligned header'>"); _str.AppendLine(" <i class='close icon link font-th regular black btnclose'></i>"); _str.AppendLine(" </div>"); _str.AppendLine("</div>"); _str.AppendLine("<div class='view paddingTop5'>"); _str.AppendLine(" <div class='iform'>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='col1 iform-col'>"); _str.AppendLine(" <div class='avatar profilepicture'>"); _str.AppendLine(" <div class='watermark'></div>"); _str.AppendLine(" <img />"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col2 iform-col'>"); _str.AppendLine(" <div class='iform'>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='col21 iform-col label-col left aligned'>"); _str.AppendLine(" <span class='lang lang-th f10 font-th regular black'>รหัสนักศึกษา</span>"); _str.AppendLine(" <span class='lang lang-en f10 font-en regular black'>Student ID</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col22 iform-col input-col left aligned'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular blue'>{0}</span>", _studentCode); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular blue'>{0}</span>", _studentCode); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='col21 iform-col label-col left aligned'>"); _str.AppendLine(" <span class='lang lang-th f10 font-th regular black'>ชื่อ - สกุล</span>"); _str.AppendLine(" <span class='lang lang-en f10 font-en regular black'>Full Name</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col22 iform-col input-col left aligned'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular blue'>{0}</span>", _fullNameTH); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular blue'>{0}</span>", _fullNameEN); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='col21 iform-col label-col left aligned'>"); _str.AppendLine(" <span class='lang lang-th f10 font-th regular black'>คณะ</span>"); _str.AppendLine(" <span class='lang lang-en f10 font-en regular black'>Faculty</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col22 iform-col input-col left aligned'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular blue'>{0}</span>", _facultyNameTH); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular blue'>{0}</span>", _facultyNameEN); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='col21 iform-col label-col left aligned'>"); _str.AppendLine(" <span class='lang lang-th f10 font-th regular black'>หลักสูตร</span>"); _str.AppendLine(" <span class='lang lang-en f10 font-en regular black'>Program</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col22 iform-col input-col left aligned'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular blue'>{0}</span>", _programNameTH); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular blue'>{0}</span>", _programNameEN); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='col21 iform-col label-col left aligned'>"); _str.AppendLine(" <span class='lang lang-th f10 font-th regular black'>ทุน</span>"); _str.AppendLine(" <span class='lang lang-en f10 font-en regular black'>Scholarship</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col22 iform-col input-col left aligned'>"); _str.AppendLine(" <div class='info-list'>"); _str.AppendLine(" <ul>"); _paramSearch.Clear(); _paramSearch.Add("Keyword", _studentCode); DataSet _ds1 = SCHDB.GetListTranStudentManageScholarship(_username, _userlevel, _systemGroup, _paramSearch); foreach (DataRow _dr1 in _ds1.Tables[0].Rows) { _row = _dr1["rowNum"].ToString(); _scholarshipsNameTH = _dr1["scholarshipsNameTH"].ToString(); _scholarshipsNameEN = (!String.IsNullOrEmpty(_dr1["scholarshipsNameEN"].ToString()) ? _dr1["scholarshipsNameEN"].ToString() : (!String.IsNullOrEmpty(_scholarshipsNameTH) ? _scholarshipsNameTH : "")); _responsibleAgency = _dr1["responsibleAgency"].ToString(); _registerDate = (!String.IsNullOrEmpty(_dr1["registerDate"].ToString()) ? DateTime.Parse(_dr1["registerDate"].ToString()).ToString("dd/MM/yyyy") : ""); _scholarshipsYear = _dr1["scholarshipsYear"].ToString(); _semester = _dr1["semester"].ToString(); _str.AppendLine(" <li class='blue'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular blue'>{0}</span><span class='lang lang-th f10 font-th regular blue opacity05'>{1}</span><span class='lang lang-th f10 font-th regular blue'> ( {2} - {3} / {4} )</span>", _scholarshipsNameTH, (!String.IsNullOrEmpty(_responsibleAgency) ? (" - " + _responsibleAgency) : ""), _registerDate, _scholarshipsYear, _semester); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular blue'>{0}</span><span class='lang lang-en f10 font-en regular blue opacity05'>{1}</span><span class='lang lang-en f10 font-en regular blue'> ( {2} - {3} / {4} )</span>", _scholarshipsNameEN, (!String.IsNullOrEmpty(_responsibleAgency) ? (" - " + _responsibleAgency) : ""), _registerDate, _scholarshipsYear, _semester); _str.AppendLine(" </li>"); } _ds1.Dispose(); _str.AppendLine(" </ul>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='col21 iform-col label-col left aligned'>"); _str.AppendLine(" <span class='lang lang-th f10 font-th regular black'>สถานภาพ</span>"); _str.AppendLine(" <span class='lang lang-en f10 font-en regular black'>Student Status</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col22 iform-col input-col left aligned'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular blue'>{0}</span>", _statusTypeNameTH); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular blue'>{0}</span>", _statusTypeNameEN); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='iform'>"); _str.AppendLine(" <div class='iform-row'>"); _str.AppendLine(" <div class='iform-col'>"); _str.AppendLine(" <div class='ui segment list-grade'>"); _str.AppendLine(" <div class='ui middle aligned divided list'>"); _str.AppendLine(" <div class='item'>"); _str.AppendLine(" <div class='content'>"); _str.AppendLine(" <div class='col1 list-col left floated left aligned header'>"); _str.AppendLine(" <span class='lang lang-th f9 font-th regular black'>ภาคการศึกษา</span>"); _str.AppendLine(" <span class='lang lang-en f9 font-en regular black'>Semester</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col2 list-col left aligned header'>"); _str.AppendLine(" <span class='lang lang-th f9 font-th regular black'>เกรดเฉลี่ย</span>"); _str.AppendLine(" <span class='lang lang-en f9 font-en regular black'>GPA</span>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); DataSet _ds2 = SCHDB.GetStudentGPA(_dataRecorded["StudentCode"].ToString()); foreach (DataRow _dr2 in _ds2.Tables[0].Rows) { _str.AppendLine(" <div class='item'>"); _str.AppendLine(" <div class='col1 list-col left floated left aligned content'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular black'>{0}</span>", _dr2["sem"].ToString()); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular black'>{0}</span>", _dr2["sem"].ToString()); _str.AppendLine(" </div>"); _str.AppendLine(" <div class='col2 list-col left aligned content'>"); _str.AppendFormat(" <span class='lang lang-th f10 font-th regular black'>{0}</span>", _dr2["cGPA"].ToString()); _str.AppendFormat(" <span class='lang lang-en f10 font-en regular black'>{0}</span>", _dr2["cGPA"].ToString()); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); } _ds2.Dispose(); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine(" </div>"); _str.AppendLine("</div>"); return(_str); }