浏览:1702008-05-20 19:33   来自向上的车轮      :

请问自定义列DataGridViewComBoxColumn如何实现显示值和值列啊?
就是实现如下两个属性 一个只是显示给界面查看,另一个是真实的存入数据库的值
DataGridViewCell.FormattedValue 
DataGridViewCell.Value
现在我遇到的问题是要么都是显示值 要么都是存储值?如何分开呢?请大家赐教! 

类似DataGridViewComboBoxColumn?

有DataSource 属性,DisplayMember 和ValueMember  ,最好是下拉datagridview

当取datagridviewcell的Value时是值FormattedValue 是用户看到的显示描述 

我试过许多方法 屡试不爽。FormattedValue 与value总是一样的 ?请大家帮忙哦 

请查看下面的代码
http://forums.microsoft.com/china/ShowPost.aspx?siteid=15&postid=3370339

 

http://topic.csdn.net/u/20080509/08/7f558c89-ea98-44f9-a1d4-159674dcfab8.html

楼主

你还不是小组成员,加入小组以后才能发布新主题!
> 返回“Visual Studio”


其他话题

相关链接
1 33837