在获取空值时避免在reportviewer上使用#Error标签 [英] Avoid #Error Label on reportviewer while getting null value

查看:69
本文介绍了在获取空值时避免在reportviewer上使用#Error标签的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

我在使用reportviewer时遇到问题,
当数据集中的值为空时,它将显示#Error标签而不是空白字段.
我该如何替换或隐藏将空值插入空白字段?

我尝试过= iff(fields!fieldName.value = Nothing,",fieldName.value = Nothing)(报告)

(没有工作)

感谢Roy

Hi There,

i have problem using reportviewer, 
when the values in the dataset are null it will show #Error label instead of blank field.
how can i replace or hide the null value into blank field ?

i tried =iff(fields!fieldName.value=Nothing,"",fieldName.value=Nothing)  (on report)

(didn't work)

thanks
Roy

推荐答案

C#中没有IIF.您可以使用?

布尔值=(fieldName.Value == null?true:false);
There is no IIF in C#. You can use ?

bool value = (fieldName.Value == null ? true : false);


这篇关于在获取空值时避免在reportviewer上使用#Error标签的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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