Example #1
0
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         string startPath = Application.StartupPath + "\\report\\药品库存清单.grf";
         if (chkIsShowNoStore.Checked == true)
         {
             string    filterWhere = "PACKNUM<>0 OR BASENUM<>0";
             DataRow[] filterRows  = _storeDt.Select(filterWhere);
             DataTable filterDt    = _storeDt.Clone();
             foreach (DataRow dRow in filterRows)
             {
                 filterDt.Rows.Add(dRow.ItemArray);
             }
             YP_Printer.PrintStoreBill(startPath, (int)_currentUser, (int)_currentDept, filterDt, _belongSystem);
         }
         else
         {
             YP_Printer.PrintStoreBill(startPath, (int)_currentUser, (int)_currentDept, _storeDt, _belongSystem);
         }
     }
     catch (Exception error)
     {
         MessageBox.Show(error.Message);
     }
 }
 private void btnPrint_Click(object sender, EventArgs e)
 {
     try
     {
         string startPath = Application.StartupPath + "\\report\\药品库存清单.grf";
         YP_Printer.PrintStoreBill(startPath, (int)_currentUserId, (int)_currentDeptId, _drugStoreInfoDt, _belongSystem);
     }
     catch (Exception error)
     {
         MessageBox.Show(error.Message);
     }
 }