Пример #1
0
        private void ResetControls()
        {
            //setting up the variabvles
            int intCounter;
            int intNumberOfRecords;

            txtAssignedProjectID.Text = "";
            txtCustomerProjectID.Text = "";
            ClearRadioButtons();
            ClearDateEntryControls();
            SetControlsReadOnly(false);
            gblnDoNotRun = false;

            //loading up the combo boxes
            cboSelectManager.Items.Clear();

            TheFindProductionManagersDataSet = TheEmployeeClass.FindProductionManagers();
            cboSelectManager.Items.Add("Select Manager");
            intNumberOfRecords = TheFindProductionManagersDataSet.FindProductionManagers.Rows.Count - 1;

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectManager.Items.Add(TheFindProductionManagersDataSet.FindProductionManagers[intCounter].FullName);
            }

            cboSelectManager.SelectedIndex = 0;

            cboSelectDepartment.Items.Clear();
            cboSelectDepartment.Items.Add("Select Department");

            TheFindSortedCustomerLinesDataSet = TheDepartmentClass.FindSortedCustomerLines();

            intNumberOfRecords = TheFindSortedCustomerLinesDataSet.FindSortedCustomerLines.Rows.Count - 1;

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectDepartment.Items.Add(TheFindSortedCustomerLinesDataSet.FindSortedCustomerLines[intCounter].Department);
            }

            cboSelectDepartment.SelectedIndex = 0;

            cboSelectOffice.Items.Clear();
            cboSelectOffice.Items.Add("Select Office");

            TheFindWarehousesDataSet = TheEmployeeClass.FindWarehouses();
            intNumberOfRecords       = TheFindWarehousesDataSet.FindWarehouses.Rows.Count - 1;

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectOffice.Items.Add(TheFindWarehousesDataSet.FindWarehouses[intCounter].FirstName);
            }

            cboSelectOffice.SelectedIndex   = 0;
            expAddEditProjectInfo.IsEnabled = false;
        }
Пример #2
0
        public FindProductionManagersDataSet FindProductionManagers()
        {
            try
            {
                aFindProductionManagersDataSet      = new FindProductionManagersDataSet();
                aFindProductionManagersTableAdapter = new FindProductionManagersDataSetTableAdapters.FindProductionManagersTableAdapter();
                aFindProductionManagersTableAdapter.Fill(aFindProductionManagersDataSet.FindProductionManagers);
            }
            catch (Exception Ex)
            {
                TheEventLogClass.InsertEventLogEntry(DateTime.Now, "Employee Class // Find Production Managers " + Ex.Message);
            }

            return(aFindProductionManagersDataSet);
        }
Пример #3
0
        private void rdoSelectManager_Checked(object sender, RoutedEventArgs e)
        {
            //setting up local variables
            int intCounter;
            int intNumberOfRecords;

            try
            {
                lblSelectManger.Visibility  = Visibility.Visible;
                cboSelectManager.Visibility = Visibility.Visible;

                TheEmployeeProductionPunchDataSet.employees.Rows.Clear();

                dgrResults.ItemsSource = TheEmployeeProductionPunchDataSet.employees;

                cboSelectManager.Items.Clear();
                cboSelectManager.Items.Add("Select Manager");

                TheFindProductionManagersDataSet = TheEmployeeClass.FindProductionManagers();

                intNumberOfRecords = TheFindProductionManagersDataSet.FindProductionManagers.Rows.Count;

                for (intCounter = 0; intCounter < intNumberOfRecords; intCounter++)
                {
                    cboSelectManager.Items.Add(TheFindProductionManagersDataSet.FindProductionManagers[intCounter].FullName);
                }

                cboSelectManager.SelectedIndex = 0;
            }
            catch (Exception Ex)
            {
                TheEventLogClass.InsertEventLogEntry(DateTime.Now, "New Blue Jay ERP // Employee Punched Vs Production Hours // Select Manager Radio Button " + Ex.Message);

                TheMessagesClass.ErrorMessage(Ex.ToString());
            }
        }
Пример #4
0
        private void ResetControls()
        {
            //setting local variables
            int intCounter;
            int intNumberOfRecords;

            txtEndDate.Text   = "";
            txtStartDate.Text = "";
            TheEmployeePunchesProductivityDataSet.employeepunchesproductivity.Rows.Clear();
            dgrResults.ItemsSource = TheEmployeePunchesProductivityDataSet.employeepunchesproductivity;

            TheFindProductionManagersDataSet = TheEmployeeClass.FindProductionManagers();

            intNumberOfRecords = TheFindProductionManagersDataSet.FindProductionManagers.Rows.Count - 1;
            cboSelectManager.Items.Clear();
            cboSelectManager.Items.Add("Select Manager");

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectManager.Items.Add(TheFindProductionManagersDataSet.FindProductionManagers[intCounter].FullName);
            }

            cboSelectManager.SelectedIndex = 0;
        }
Пример #5
0
        private void ResetControls()
        {
            //setting up the variabvles
            int intCounter;
            int intNumberOfRecords;
            int intSelectedIndex = 0;

            txtAssignedProjectID.Text = "";
            txtCustomerProjectID.Text = "";
            ClearDateEntryControls();
            SetControlsReadOnly(false);
            expProecess.IsEnabled = true;

            //loading up the combo boxes
            cboSelectManager.Items.Clear();

            TheFindProductionManagersDataSet = TheEmployeeClass.FindProductionManagers();
            cboSelectManager.Items.Add("Select Manager");
            intNumberOfRecords = TheFindProductionManagersDataSet.FindProductionManagers.Rows.Count - 1;

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectManager.Items.Add(TheFindProductionManagersDataSet.FindProductionManagers[intCounter].FullName);
            }

            cboSelectManager.SelectedIndex = 0;

            cboSelectDepartment.Items.Clear();
            cboSelectDepartment.Items.Add("Select Department");

            TheFindSortedCustomerLinesDataSet = TheDepartmentClass.FindSortedCustomerLines();

            intNumberOfRecords = TheFindSortedCustomerLinesDataSet.FindSortedCustomerLines.Rows.Count - 1;

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectDepartment.Items.Add(TheFindSortedCustomerLinesDataSet.FindSortedCustomerLines[intCounter].Department);
            }

            cboSelectDepartment.SelectedIndex = 0;

            cboSelectOffice.Items.Clear();
            cboSelectOffice.Items.Add("Select Office");

            TheFindWarehousesDataSet = TheEmployeeClass.FindWarehouses();
            intNumberOfRecords       = TheFindWarehousesDataSet.FindWarehouses.Rows.Count - 1;

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectOffice.Items.Add(TheFindWarehousesDataSet.FindWarehouses[intCounter].FirstName);
            }

            cboSelectOffice.SelectedIndex = 0;

            cboSelectStatus.Items.Clear();
            cboSelectStatus.Items.Add("Select Status");

            TheFindWorkOrderStatusSortedDataSet = TheWorkOrderClass.FindWorkOrderStatusSorted();

            cboSelectStatus.IsEnabled = true;

            intNumberOfRecords = TheFindWorkOrderStatusSortedDataSet.FindWorkOrderStatusSorted.Rows.Count - 1;

            for (intCounter = 0; intCounter <= intNumberOfRecords; intCounter++)
            {
                cboSelectStatus.Items.Add(TheFindWorkOrderStatusSortedDataSet.FindWorkOrderStatusSorted[intCounter].WorkOrderStatus);

                if (TheFindWorkOrderStatusSortedDataSet.FindWorkOrderStatusSorted[intCounter].WorkOrderStatus == "OPEN")
                {
                    intSelectedIndex = intCounter + 1;
                }
            }

            cboSelectStatus.SelectedIndex = intSelectedIndex;

            cboSelectStatus.IsEnabled = false;

            rdoOverNo.Visibility  = Visibility.Hidden;
            rdoOverYes.Visibility = Visibility.Hidden;
        }