Ejemplo n.º 1
0
 public CarEl3htaCreate(CarEl3hata carEl3hata, XtraTabControl xtraTabControlCarsContent)
 {
     try
     {
         InitializeComponent();
         dbconnection      = new MySqlConnection(connection.connectionString);
         groupBox1.Visible = false;
         this.carEl3hata   = carEl3hata;
         this.xtraTabControlCarsContent = xtraTabControlCarsContent;
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
Ejemplo n.º 2
0
 public CarElahataUpdate(int id, CarEl3hata carEl3hata, XtraTabControl xtraTabControlCarsContent)
 {
     try
     {
         ID = id;
         InitializeComponent();
         dbconnection = new MySqlConnection(connection.connectionString);
         this.xtraTabControlCarsContent = xtraTabControlCarsContent;
         this.carEl3hata = carEl3hata;
         data            = new List <string>();
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
Ejemplo n.º 3
0
        //El3hata
        public void bindRecordEl3hataForm(CarEl3hata carEl3hata)
        {
            CarEl3htaCreate objForm = new CarEl3htaCreate(carEl3hata, 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();
        }
Ejemplo n.º 4
0
        public void bindUpdateEl3hataForm(DataRowView El3htaRow, CarEl3hata carEl3hata)
        {
            CarElahataUpdate objForm = new CarElahataUpdate(Convert.ToInt16(El3htaRow[0].ToString()), carEl3hata, 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();
        }
Ejemplo n.º 5
0
        //el3hata
        private void navBarItem5_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;

                CarEl3hata objForm = new CarEl3hata(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);
            }
        }