空网格视图消息 [英] Empty Grid view message
本文介绍了空网格视图消息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你好,
我有一个gridview.
最初,我在其中选择(项目)行,并在文本框中显示这些行,然后选择该特定行,然后使用gridview.selectedrow.visible = false隐藏该行.
稍后,如果其中没有行,我需要获得一个警告框,显示没有剩余的项目.
谢谢.
Hello,
I have a gridview.
Initially I am selecting rows (of items) in it and displaying those in textboxes and after selecting that particular row, I am hiding that row using gridview.selectedrow.visible=false.
The later, If there are no rows are there in it, I need to get a alert box displaying that there are no items left.
Thanks.
推荐答案
尝试一下,
try this,
if (dataGridView1.RowCount == dataGridView1.SelectedRows.Count)
{
// alert message
}
这篇关于空网格视图消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文