Ejemplo n.º 1
0
 private void expensType_Load(object sender, EventArgs e)
 {
     DT = Dom_SqlClass.retriveData("ExpenseType", "Where 1=1", new string[] { "*" });
     dataTypeExpens.DataSource = DT;
     dom_Design.GenerateColumHeader(new string[] { "លេខកូដសម្គាល់", "ឈ្មោះប្រភេទចំណាយ" }, dataTypeExpens.ColumnCount, dataTypeExpens);
     ID         = dom_Design.GenerateID(Dom_SqlClass.GetIDFromDB("ExpTypeID", "_", "ExpenseType"), "EXT_00");
     txtID.Text = ID;
     dataTypeExpens.ClearSelection();
 }
Ejemplo n.º 2
0
 private void Customer_Load(object sender, EventArgs e)
 {
     string[] columnHeaderName = { "លេខកូដសម្គាល់", "នាមត្រកូល", "គោត្តនាម-នាមខ្លួន", "ភេទ", "លេខអត្តសញ្ញាណប័ណ្ណ", "លេខទូរស័ព្ទ" };
     DT = Dom_SqlClass.retriveData("Customer", "Where 1=1", new string[] { "*" });
     dataCustomer.DataSource = DT;
     String[] Name = { "CusID", "FName", "LName", "Gender", "IDNum", "Tel" };
     dom_Design.ColumnName(dataCustomer, 6, Name);
     dom_Design.GenerateColumHeader(columnHeaderName, dataCustomer.ColumnCount, dataCustomer);
     Dom_SqlClass.GetIDFromDB("cusID", "_", "customer");
     ID         = dom_Design.GenerateID(Dom_SqlClass.GetIDFromDB("cusID", "_", "customer"), "Cus_00");
     txtID.Text = ID;
     dataCustomer.ClearSelection();
     txtFname.Focus();
 }
Ejemplo n.º 3
0
 private void cmCustomer_TextChanged(object sender, EventArgs e)
 {
     if (cmCustomer.SelectedIndex == -1)
     {
         foreach (String S in cmCustomer.Items)
         {
             if (cmCustomer.Text.ToLower() != S.ToLower())
             {
                 if (IDCus == "")
                 {
                     IDCus = dom_Design.GenerateID(Dom_SqlClass.GetIDFromDB("cusID", "_", "customer"), "Cus_00");
                 }
                 else
                 {
                     IDCus = dom_Design.GenerateID(IDCus, "Cus_00");
                 }
                 txtIDCus.Text = IDCus;
             }
         }
     }
     else
     {
     }
 }
Ejemplo n.º 4
0
 private void Expense_Load(object sender, EventArgs e)
 {
     ID         = dom_Design.GenerateID(Dom_SqlClass.GetIDFromDB("ExpID", "_", "Expense"), "EXP_00");
     txtID.Text = ID;
     Dom_SqlClass.FillItemToCombobox("SELECT ExpTypeID,ExpDesc FROM ExpenseType", "ExpTypeID", "ExpDesc", cmType);
 }