日期:2014-05-17  浏览次数:20759 次

数据库内bool类型的值如何显示在datagridview中combobox上
我从数据库读出来一列为bool类型,想显示在datagridview中的combobox上,如果读出来的是true 下拉列表显示 原件,为false显示 复印件, 求高手解答

------解决方案--------------------
            bool b=true;
            cb.Text = b ? "原件" : "复印件";

------解决方案--------------------
select case 字段 when 1 then '原件' else '复印件' end as 类型 from 表;


------解决方案--------------------
select case filetype when 1 then 'True' else 'False' end as 类型 from 表;

------解决方案--------------------
grvresult_RowDataBound  事件里面写
------解决方案--------------------
引用:
引用:grvresult_RowDataBound  事件里面写
你确定是这个事件??? 我怎么找不到 这个事件

我看成gridview  你去找他的事件