zzr99
2022-06-17 5b7184598c83f56080eb0a336f28d06b202a151f
WorkM/Á÷ת¿¨¹ÜÀí/MES_StationInBill.cs
@@ -138,6 +138,7 @@
        //取消按钮
        private void cmdCancel_Click(object sender, EventArgs e)
        {
            ClsPub.SaveGridView(grdSub, Name+"grdSub", ClsPub.AppPath);//设置列宽
            this.Close();
        }
        //控件位置
@@ -414,7 +415,8 @@
            txtHProcNo.Enabled = false;
            //加载 é…ä»¶ç»‘定清单
            HInterID = BillOld.omodel.HInterID;
            DisplaySub();
@@ -1510,9 +1512,13 @@
                DataSet Dsplay;
                Dsplay = oCn.RunProcReturn("exec h_p_MES_StationInBillSub_BindDisplay   " + HInterID.ToString() + "  ", "h_p_MES_StationInBillSub_BindDisplay");
                //写入信息
                if (Dsplay == null || Dsplay.Tables[0].Rows.Count == 0)
                if (Dsplay == null )
                {
                    MessageBox.Show("刷新失败!");
                    return;
                }
                else if(Dsplay.Tables[0].Rows.Count == 0)
                {
                    return;
                }
                else
@@ -1536,5 +1542,25 @@
                MessageBox.Show(e.Message + "DisplaySub");
            }
        }
        private void cmdDelLine_Click(object sender, EventArgs e)
        {
            try
            {
                //根据选择的条形码 æ¥åˆ é™¤
                if (grdSub.CurrentRow == null)
                    return;
                string sBarCode = DBUtility.ClsPub.isStrNull(grdSub.Rows[grdSub.CurrentRow.Index].Cells[Fun_GetCol("条形码")].Value);
                SQLHelper.ClsCN oCn = new ClsCN();
                oCn.RunProc(" delete from Sc_StationInBillSub_BindBarCodeTemp " +
                    "Where  HInterID = "+ HInterID.ToString() +" and HBarCode = '"+ sBarCode + "'");
                DisplaySub();
            }
            catch (Exception e1)
            {
                MessageBox.Show("删除行失败!"+e1.Message);
            }
        }
    }
}