Ejemplo n.º 1
0
 public static void GeneratePasswordFile()
 {
     try
     {
         EXCEL_ERP_TESTEntities _conn = new EXCEL_ERP_TESTEntities();
         string strLine             = string.Empty;
         List <TBL_User_Master> lst = _conn.TBL_User_Master.Where(x => x.IsActive == true).ToList();
         string[] lines             = new string[lst.Count];
         int      i = 0;
         foreach (TBL_User_Master item in lst)
         {
             lines[i++] = string.Format("\n{0}\t{1}\t{2}",
                                        item.TBL_MP_Master_Employee.EmployeeCode,
                                        item.TBL_MP_Master_Employee.EmployeeName,
                                        DecryptText(item.LoginPassword));
         }
         System.IO.File.WriteAllLines(@"C:\Users\sachin\Desktop\Passwords.txt", lines);
     }
     catch (Exception ex)
     {
         string errMessage = ex.Message;
         if (ex.InnerException != null)
         {
             errMessage += string.Format("\n\n{0}", ex.InnerException.Message);
         }
         MessageBox.Show(errMessage, "AppCommon::GeneratePasswordFile", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Ejemplo n.º 2
0
 public void RefreshDatabase()
 {
     try
     {
         _dbContext = new EXCEL_ERP_TESTEntities();
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message, "appWorkUnit::RefreshDatabase", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Ejemplo n.º 3
0
 public static void SetShiftStartFromAndToDatetime(ref DateTime start, ref DateTime end)
 {
     try
     {
         EXCEL_ERP_TESTEntities      conn    = new EXCEL_ERP_TESTEntities();
         TBL_MP_Admin_Company_Master dbModel = conn.TBL_MP_Admin_Company_Master.FirstOrDefault();
         if (dbModel != null)
         {
             //format 05:15 PM
             start = ConvertToDateTime(start.ToString("dd-MM-yyyy"), dbModel.ShiftTimeFrom);
             end   = ConvertToDateTime(end.ToString("dd-MM-yyyy"), dbModel.ShiftTimeTo);
         }
     }
     catch (Exception ex)
     {
         string errMessage = ex.Message;
         if (ex.InnerException != null)
         {
             errMessage += string.Format("\n\n{0}", ex.InnerException.Message);
         }
         MessageBox.Show(errMessage, "AppCommon::SetShiftStartFromAndToDatetime", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Ejemplo n.º 4
0
 public ServiceVoucherNoSetup()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 5
0
 public ServiceCompanyMaster(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 6
0
 public ServiceProject()
 {
     _dbContext = new EXCEL_ERP_TESTEntities(); PopulateStatusVariables();
 }
Ejemplo n.º 7
0
 public ServiceLoanRequest()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
     PopulateStatusVariables();
 }
Ejemplo n.º 8
0
 public ServiceCheckListMaster()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 9
0
 public ServiceContacts()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 10
0
 public ServiceRoles(USER_SESSION currUser)
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
     CURR_USER  = currUser;
 }
Ejemplo n.º 11
0
 public ServiceProjectCheckList(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 12
0
 public ServiceAppDefaults()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 13
0
 public ServiceAppDefaults(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 14
0
 public ServiceOrgChart()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 15
0
 public ServiceOrgChart(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 16
0
 public ServiceFollowUps(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 17
0
 public ServiceFollowUps()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 18
0
 public ServiceProjectCheckList()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 19
0
 public ServiceContacts(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 20
0
 public ServiceModules(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 21
0
 public ServiceAdvanceRequest(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
     PopulateStatusVariables();
 }
Ejemplo n.º 22
0
 public ServiceModules()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 23
0
 public ServiceCheckListMaster(EXCEL_ERP_TESTEntities conn)
 {
     _dbContext = conn;
 }
Ejemplo n.º 24
0
 public ServiceLeaveConfiguration(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 25
0
 public ServiceProject(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
     //   PopulateStatusVariables();
 }
Ejemplo n.º 26
0
 public ServiceLeaveConfiguration()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
Ejemplo n.º 27
0
 public ServiceSalesQuestionnaire(EXCEL_ERP_TESTEntities conn)
 {
     _dbContext = conn; PopulateQuestionnairePublicVariables();
 }
 public ServiceSalesQuotationReview(EXCEL_ERP_TESTEntities _context)
 {
     _dbContext = _context;
 }
Ejemplo n.º 29
0
 public ServiceCompanyMaster()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }
 public ServiceSalesQuotationReview()
 {
     _dbContext = new EXCEL_ERP_TESTEntities();
 }