Example #1
0
        private void btnAdd_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            //frmAddProductSize frmAdd = new frmAddProductSize(preProductSize);
            //frmAdd.ShowDialog();
            frmAddProductSize frmAdd = new frmAddProductSize(preProductSize, this);

            frmAdd.WindowState     = FormWindowState.Maximized;
            frmAdd.FormBorderStyle = FormBorderStyle.None;
            frmAdd.MdiParent       = this.MdiParent;
            frmAdd.Dock            = DockStyle.Fill;
            frmAdd.Show();
        }
Example #2
0
        //btnUpdate
        private void repositoryItemButtonEdit1_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e)
        {
            GridView gridView = gridProductSize.FocusedView as GridView;

            Model.PRODUCT_SIZE obj = new Model.PRODUCT_SIZE();

            obj.PRODUCT_ID        = Convert.ToInt32(gridView.GetFocusedRowCellValue("PRODUCT_ID").ToString());
            obj.SIZE              = gridView.GetFocusedRowCellValue("SIZE").ToString();
            obj.IN_STOCK_QUANTITY = Convert.ToInt32(gridView.GetFocusedRowCellValue("IN_STOCK_QUANTITY").ToString());

            //frmAddProductSize frmAdd = new frmAddProductSize(preProductSize, obj);
            //frmAdd.ShowDialog();
            frmAddProductSize frmAdd = new frmAddProductSize(preProductSize, obj, this);

            frmAdd.WindowState     = FormWindowState.Maximized;
            frmAdd.FormBorderStyle = FormBorderStyle.None;
            frmAdd.MdiParent       = this.MdiParent;
            frmAdd.Dock            = DockStyle.Fill;
            frmAdd.Show();
        }