Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有gridview,它填充了数据。想在鼠标右键单击事件上启用删除按钮。怎么可能?请帮助我?
尝试这个
this.GridView.MouseDown += new System.Windows.Forms.MouseEventHandler(this.GridView_MouseDown); private void GridView_MouseDown(object sender, MouseEventArgs e) { if(e.Button == MouseButtons.Right) { //code to enable a button } }