wpf TextBox 自定义菜单
右键菜单 ContextMenu cont = new ContextMenu(); cont.Items.Add(new MenuItem() { Header="删除"}); cont.Items.Add(new MenuItem() { Header = "添加" }); textBox1.ContextMenu = cont; for (int i = 0; i < cont.Items.Count; i++) { MenuItem i
右键菜单 ContextMenu cont = new ContextMenu(); cont.Items.Add(new MenuItem() { Header="删除"}); cont.Items.Add(new MenuItem() { Header = "添加" }); textBox1.ContextMenu = cont; for (int i = 0; i < cont.Items.Count; i++) { MenuItem i