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); } }
public void RefreshDatabase() { try { _dbContext = new EXCEL_ERP_TESTEntities(); } catch (Exception ex) { MessageBox.Show(ex.Message, "appWorkUnit::RefreshDatabase", MessageBoxButtons.OK, MessageBoxIcon.Error); } }
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); } }
public ServiceVoucherNoSetup() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceCompanyMaster(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceProject() { _dbContext = new EXCEL_ERP_TESTEntities(); PopulateStatusVariables(); }
public ServiceLoanRequest() { _dbContext = new EXCEL_ERP_TESTEntities(); PopulateStatusVariables(); }
public ServiceCheckListMaster() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceContacts() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceRoles(USER_SESSION currUser) { _dbContext = new EXCEL_ERP_TESTEntities(); CURR_USER = currUser; }
public ServiceProjectCheckList(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceAppDefaults() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceAppDefaults(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceOrgChart() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceOrgChart(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceFollowUps(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceFollowUps() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceProjectCheckList() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceContacts(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceModules(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceAdvanceRequest(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; PopulateStatusVariables(); }
public ServiceModules() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceCheckListMaster(EXCEL_ERP_TESTEntities conn) { _dbContext = conn; }
public ServiceLeaveConfiguration(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceProject(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; // PopulateStatusVariables(); }
public ServiceLeaveConfiguration() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceSalesQuestionnaire(EXCEL_ERP_TESTEntities conn) { _dbContext = conn; PopulateQuestionnairePublicVariables(); }
public ServiceSalesQuotationReview(EXCEL_ERP_TESTEntities _context) { _dbContext = _context; }
public ServiceCompanyMaster() { _dbContext = new EXCEL_ERP_TESTEntities(); }
public ServiceSalesQuotationReview() { _dbContext = new EXCEL_ERP_TESTEntities(); }