private void Window_Loaded(object sender, RoutedEventArgs e) { int intEmployeeID; try { TheFindAlohaTimePunchesByTransactionIDDataSet = TheEmployeePunchedHoursClass.FindAlohaTimePunchesByTransactionID(MainWindow.gintTransactionID); intEmployeeID = TheFindAlohaTimePunchesByTransactionIDDataSet.FindAlohaTimePunchesByTransactionID[0].EmployeeID; TheFindEmployeeByEmployeeIDDataSet = TheEmployeeClass.FindEmployeeByEmployeeID(intEmployeeID); txtEmployeeID.Text = Convert.ToString(intEmployeeID); txtEndDate.Text = Convert.ToString(TheFindAlohaTimePunchesByTransactionIDDataSet.FindAlohaTimePunchesByTransactionID[0].EndDate); txtFirstName.Text = TheFindEmployeeByEmployeeIDDataSet.FindEmployeeByEmployeeID[0].FirstName; txtHours.Text = Convert.ToString(TheFindAlohaTimePunchesByTransactionIDDataSet.FindAlohaTimePunchesByTransactionID[0].DailyHours); txtLastName.Text = TheFindEmployeeByEmployeeIDDataSet.FindEmployeeByEmployeeID[0].LastName; txtStartDate.Text = Convert.ToString(TheFindAlohaTimePunchesByTransactionIDDataSet.FindAlohaTimePunchesByTransactionID[0].StartDate); txtTransactionID.Text = Convert.ToString(MainWindow.gintTransactionID); } catch (Exception Ex) { TheEventLogClass.InsertEventLogEntry(DateTime.Now, "New Blue Jay ERP // Change Aloha Times // Window Loaded " + Ex.Message); TheMessagesClass.ErrorMessage(Ex.ToString()); } }
public FindAlohaTimePunchesByTransactionIDDataSet FindAlohaTimePunchesByTransactionID(int intTransactionID) { try { aFindAlohaTimePunchesByTransactionIDDataSet = new FindAlohaTimePunchesByTransactionIDDataSet(); aFindAlohaTimePunchesByTransactionIDTableAdapter = new FindAlohaTimePunchesByTransactionIDDataSetTableAdapters.FindAlohaTimePunchesByTransactionIDTableAdapter(); aFindAlohaTimePunchesByTransactionIDTableAdapter.Fill(aFindAlohaTimePunchesByTransactionIDDataSet.FindAlohaTimePunchesByTransactionID, intTransactionID); } catch (Exception Ex) { TheEventLogClass.InsertEventLogEntry(DateTime.Now, "Employee Punched Hours Class // Find Aloha Time Punches By Transaction ID " + Ex.Message); } return(aFindAlohaTimePunchesByTransactionIDDataSet); }