예제 #1
0
        private void sGeneralCode()
        {
            DataTable tb = new DataTable();

            tb = boLop.getLOP_LastCode();
            string lCode = String.Empty;

            if (tb.Rows.Count == 0)
            {
                lCode = "000000";
            }
            else
            if (tb.Rows.Count > 0)
            {
                lCode = tb.Rows[0]["LastCode"].ToString();
            }

            txtCode.Text = ("LOP" + quydinh.LaySTT(int.Parse(lCode.ToString()) + 1)).ToString();
            sStatust     = int.Parse(lCode.ToString());
        }