protected void btnAdd_Click(object sender, EventArgs e) { MTCSYT.SYS_Session session = (MTCSYT.SYS_Session)Session["SYS_Session"]; string strMadviqly = session.User.ma_dviqlyDN; List <Object> keyvalues = grdTram.GetSelectedFieldValues("MA_TRAM"); foreach (object key in keyvalues) { string matram = key + ""; if (!CheckName(matram)) { ScriptManager.RegisterStartupScript(Page, Page.GetType(), "", "alert('Mã trạm bị trùng');", true); return; } db.INSERT_TTTT_TRAM_UUTIEN(strMadviqly, matram); } LoadTramUT(); LoadTram(); grdTram_UT.Selection.UnselectAll(); grdTram.Selection.UnselectAll(); }