当前位置:网站首页>Press the delete key in the gridcontrol of devaxpress to delete the selected line item
Press the delete key in the gridcontrol of devaxpress to delete the selected line item
2022-07-21 15:16:00 【I Can -Jiang】
private void GC_ProcessGridKey(object sender, KeyEventArgs e)
{
DevExpress.XtraGrid.Views.Base.ColumnView view = (sender as DevExpress.XtraGrid.GridControl).FocusedView as DevExpress.XtraGrid.Views.Base.ColumnView;
if (view == null) return;
if (e.KeyCode == Keys.Delete && view.OptionsBehavior.AllowDeleteRows != DevExpress.Utils.DefaultBoolean.False && view.SelectedRowsCount > 0)
{
if (DevExpress.XtraEditors.XtraMessageBox.Show($" Are you sure you want to delete the selected {view.SelectedRowsCount} That's ok ?", " put questions to ", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
view.DeleteSelectedRows();
}
}
边栏推荐
- How to solve the garbled Chinese annotation of idea import project
- 第二章第十节:列表的补充知识点
- 金融企业出海新兴市场机遇与挑战并存,ADVANCE.AI保障其安全合规发展
- [public class preview]: cloud video conference system privatization practice
- [leetcode] 29. Divide two numbers
- 第二章 第八节:列表的增删改查
- DAMA-第四章(数据架构)
- 第二章第十二节:set集合
- 从表面看,元宇宙可能将从根本上改变人们的生产和生活方式
- 浅聊一下 布隆过滤器
猜你喜欢
Section 15 of Chapter 2: basic operation of dictionary
[CVA valuation training camp] read the annual reports of listed companies_ Lesson 2
面试中常见的的 web 安全问题
Section 12 of Chapter 2: set set
DAMA-第十二章(元数据管理)
Automatic invoice processing - get rid of the shackles of paper and data input, automate workflow and exception handling, and significantly shorten the audit preparation time
openGauss内核分析:查询重写
Intel assembly language programming learning - Chapter 5 process - Part 1
IDEA 导入项目中文注释乱码如何解决
DevExpress TreeList 实现父节点列值选中,其下子节点也全部选中
随机推荐
Web3再怎么牛 也不能逃出这几个老巨头的五指山
asp.net -编辑超链接事件
Internship: several steps to get familiar with the project code
let's go——2022年读书活动招募书(第1期)
第二章 第八节:列表的增删改查
How to ensure data security while saving 30% disk space in tdsql PG version DB · insight
DAMA-第三章(数据治理)
Header files referencing different packages in the same workspace
Section 8 of Chapter II: addition, deletion, modification and query of the list
Winform记住密码功能
Flask 源码剖析(一)请求入口
Design details related to sap e-commerce cloud Spartacus UI store
DAMA-第十章(参考数据与主数据)
【C 练习】求一个数最少需要多少步可变为斐波那契数
Spark Sql编译模块-词法、语法分析器Antlr4(一
【小程序】快来开发你的第一个微信小游戏(详细流程)
7.19 simulation summary
asp.net -GridView自带的删除行项超链接用法(DeleteButton)
Detailed explanation of TCP communication process (with case code)
Construction of combat battalion module 7 operation