public CarPartnerIncomeRecord(CarPartnerIncomes carIncomes, XtraTabControl xtraTabControlCarsContent)
 {
     try
     {
         InitializeComponent();
         dbconnection    = new MySqlConnection(connection.connectionString);
         this.carIncomes = carIncomes;
         this.xtraTabControlCarsContent = xtraTabControlCarsContent;
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
 public CarPartnerIncomeUpdate(int id, CarPartnerIncomes carIncomes, XtraTabControl xtraTabControlCarsContent)
 {
     try
     {
         ID = id;
         this.carIncomes = carIncomes;
         this.xtraTabControlCarsContent = xtraTabControlCarsContent;
         InitializeComponent();
         dbconnection = new MySqlConnection(connection.connectionString);
         data         = new List <string>();
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
Exemplo n.º 3
0
        //car Partner Incomes
        public void bindRecordPartnerIncomesForm(CarPartnerIncomes carIncomes)
        {
            CarPartnerIncomeRecord objForm = new CarPartnerIncomeRecord(carIncomes, xtraTabControlCarsContent);

            objForm.TopLevel = false;
            XtraTabPage xtraTabPage = getTabPage(xtraTabControlCarsContent, "تسجيل ايراد السيارات الخاصة");

            if (xtraTabPage == null)
            {
                xtraTabControlCarsContent.TabPages.Add("تسجيل ايراد السيارات الخاصة");
                xtraTabPage = getTabPage(xtraTabControlCarsContent, "تسجيل ايراد السيارات الخاصة");
            }
            xtraTabPage.Controls.Clear();
            xtraTabPage.Controls.Add(objForm);
            xtraTabControlCarsContent.SelectedTabPage = xtraTabPage;

            objForm.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            objForm.Dock            = DockStyle.Fill;
            objForm.Show();
        }
Exemplo n.º 4
0
        public void bindUpdatePartnerIncomesForm(DataRowView incomesRow, CarPartnerIncomes carIncomes)
        {
            CarPartnerIncomeUpdate objForm = new CarPartnerIncomeUpdate(Convert.ToInt16(incomesRow[0].ToString()), carIncomes, xtraTabControlCarsContent);

            objForm.TopLevel = false;
            XtraTabPage xtraTabPage = getTabPage(xtraTabControlCarsContent, "تعديل إيراد السيارات الخاصة");

            if (xtraTabPage == null)
            {
                xtraTabControlCarsContent.TabPages.Add("تعديل إيراد السيارات الخاصة");
                xtraTabPage = getTabPage(xtraTabControlCarsContent, "تعديل إيراد السيارات الخاصة");
            }
            xtraTabPage.Controls.Clear();
            xtraTabPage.Controls.Add(objForm);
            xtraTabControlCarsContent.SelectedTabPage = xtraTabPage;

            objForm.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            objForm.Dock            = DockStyle.Fill;
            objForm.Show();
        }
Exemplo n.º 5
0
        //partner Income
        private void navBarItem23_LinkClicked(object sender, NavBarLinkEventArgs e)
        {
            try
            {
                restForeColorOfNavBarItem();
                NavBarItem navBarItem = (NavBarItem)sender;
                navBarItem.Appearance.ForeColor = Color.Blue;
                if (!xtraTabControlCarsContent.Visible)
                {
                    xtraTabControlCarsContent.Visible = true;
                }

                XtraTabPage xtraTabPage = getTabPage(xtraTabControlCarsContent, "تقرير  حركة السيارات الخاصة");
                if (xtraTabPage == null)
                {
                    xtraTabControlCarsContent.TabPages.Add("تقرير  حركة السيارات الخاصة");
                    xtraTabPage = getTabPage(xtraTabControlCarsContent, "تقرير  حركة السيارات الخاصة");
                }

                xtraTabPage.Controls.Clear();
                xtraTabControlCarsContent.SelectedTabPage = xtraTabPage;

                CarPartnerIncomes objForm = new CarPartnerIncomes(this);

                objForm.TopLevel = false;
                xtraTabPage.Controls.Add(objForm);
                objForm.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
                objForm.Dock            = DockStyle.Fill;

                objForm.Show();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }