在checkboxlist中显示消息 [英] display message inside checkboxlist

查看:93
本文介绍了在checkboxlist中显示消息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



我正在使用checkboxlist控件并从数据集中动态填充它。我希望只要数据集中没有数据,就会在checkboxlist中显示文本消息(如No Data Avaiable)。这怎么可能?



谢谢

解决方案

 checkBoxList.Items.Add( 您的消息)。



这应该有效在Win Forms中。

如果你想要你也可以玩Enabled属性。





编辑:

读完你的评论之后,我提供的内容:

 psedocode:

如果数据集有记录,那么
show checkedListBox
else
hide checkedListBox
show message with message。





你''我必须在你的表单上贴一个标签来托管邮件。

这是你问题最简单的解决方案。



我希望这会有所帮助。


Hi all,

I am using checkboxlist control and populating it dynamically from dataset. I want to display only text message(like No Data Avaiable) inside checkboxlist whenever there is no data in dataset. How is it possible?

Thanks

解决方案

checkBoxList.Items.Add("Your message").


That should work in Win Forms.
If you want you can play with Enabled property as well.


Edit:
After reading your comment this what I have to offer:

psedocode:

if dataset has records then 
   show checkedListBox
else 
   hide checkedListBox
   show label with message.



You''ll have to a label to your form for hosting a message.
That is simplest solution for your problem.

I hope this helps.


这篇关于在checkboxlist中显示消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆