private void button2_Click(object sender, EventArgs e) { if (treeView1.SelectedNode.Text != "商品名称") { if (treeView1.SelectedNode.Parent.Text != "商品名称") { if (this.Owner is frmSellGoodInfo) { frmSellGoods selld = (frmSellGoods)this.Owner; string strName = treeView1.SelectedNode.Text; selld.txtGoodsName.Text = strName; selld.kcId = tbsell.fillfrmKcGoods(treeView1.SelectedNode.Parent.Text); selld.GoodId = treeView1.SelectedNode.Parent.Text.ToString(); this.Close(); } else if (this.Owner is frmJhGoodsInfo) { frmJhGoodsInfo jh = (frmJhGoodsInfo)this.Owner; string strName = treeView1.SelectedNode.Text; jh.txtGoodsName.Text = strName; this.Close(); } } else { MessageBox.Show("选择商品名称"); } } }
//添加商品信息 private void button1_Click(object sender, EventArgs e) { frmJhGoodsInfo JhGoods = new frmJhGoodsInfo(1); JhGoods.Owner = this; JhGoods.ShowDialog(); }
private void menuGoodsIn_Click(object sender, EventArgs e) { //进贷信息 frmJhGoodsInfo jhGOOD = new frmJhGoodsInfo(); jhGOOD.Owner = this; jhGOOD.ShowDialog(); }
private void 商品进货ToolStripMenuItem_Click(object sender, EventArgs e) { //进贷信息 frmJhGoodsInfo jhGOOD = new frmJhGoodsInfo(); jhGOOD.Owner = this; jhGOOD.ShowDialog(); }
private void button2_Click(object sender, EventArgs e) { if (treeView1.SelectedNode.Text != "") { frmJhGoodsInfo jhGood = (frmJhGoodsInfo)this.Owner; jhGood.txtJhCompName.Text = treeView1.SelectedNode.Text; this.Close(); } else { MessageBox.Show("选择供应商信息"); } }
private void menuGoodsIn_Click(object sender, EventArgs e) { //进贷信息 /* frmJhGoodsInfo jhGOOD = new frmJhGoodsInfo(); * jhGOOD.Owner = this; * jhGOOD.ShowDialog();*/ frmJhGoodsInfo delmember = new frmJhGoodsInfo(); delmember.TopLevel = false; delmember.MdiParent = this; delmember.Show(); }