我们可以将列设置为Datagridview中的组合框吗? [英] can we set the column as combobox in Datagridview.

查看:105
本文介绍了我们可以将列设置为Datagridview中的组合框吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们可以在Datagridview中将列设置为组合框吗?
对于例如

采取datagridview.
转到其属性.
转到它的列集合.
添加列.
在将列设置列类型添加到组合框时.
将列设置为组合框后,我们得到它的项目集合.
自己在这里添加项目.

现在我的问题是我可以在该单元格中看到一个连击,但看不到为什么?

请尽快回复.........

can we set the column as combobox in Datagridview.
for eg

take datagridview .
go to it''s properties.
go to it''s column collection.
add columns.
at the time adding column set column type to combobox.
after setting column as combobox we get it''s item collection.
add it''s item here it self.

now my problem is i can see a combo in that cell but i can''t see that items Why?

please reply soon............

推荐答案

它对我有用.您运行程序了吗?

如果您仍处于设计模式,则需要选择Items集合才能在列表中查看项目.
It works for me. Did you run the program?

If you''re still in design mode, then you need to select the Items collection to see the items in the list.


您也可以在代码中进行操作...
请参见此处 [ ^ ].
You can do it in code too...
See here[^].


这篇关于我们可以将列设置为Datagridview中的组合框吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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