コード例 #1
0
ファイル: Product_Display.xaml.cs プロジェクト: dangtq72/Shop
        void Product_Insert()
        {
            try
            {
                Frm_NhapHang _Frm_NhapHang = new Frm_NhapHang();
                _Frm_NhapHang.Owner = Window.GetWindow(this);
                _Frm_NhapHang.ShowDialog();

                if (_Frm_NhapHang.c_id_insert != 0)
                {
                    LoadData();

                    for (int i = 0; i < c_lst.Count; i++)
                    {
                        Product_Info ui = (Product_Info)c_lst[i];
                        if (ui.Supplier_Id == _Frm_NhapHang.c_id_insert)
                        {
                            c_row_select = i;
                            _Frm_NhapHang.c_id_insert = 0;
                            break;
                        }
                    }
                }

                DataGridHelper.NVSFocus(dgrProduct, c_row_select, 0);
            }
            catch (Exception ex)
            {
                CommonData.log.Error(ex.ToString());
            }
        }
コード例 #2
0
 private void rbn_Receive_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         Frm_NhapHang _Frm_NhapHang = new Frm_NhapHang();
         _Frm_NhapHang.Owner = Window.GetWindow(this);
         _Frm_NhapHang.ShowDialog();
     }
     catch (Exception ex)
     {
         CommonData.log.Error(ex.ToString());
     }
 }