This is a migrated thread and some comments may be shown as answers.

Change query result in report viewer

4 Answers 92 Views
Report Designer (standalone)
This is a migrated thread and some comments may be shown as answers.
Ricardo
Top achievements
Rank 1
Ricardo asked on 02 Apr 2013, 01:25 PM
Hello Guys, 

In my DB I have a column with bool value, when I get a report my report viewer show this column as "TRUE" or "FALSE", I want change this report viewer to show "YES" and "NO". How can I do this?

I posted in attach a image showing this.

Thanks!

4 Answers, 1 is accepted

Sort by
0
erwin
Top achievements
Rank 1
Veteran
answered on 02 Apr 2013, 02:14 PM
You can use the IIf Function in the Value Property of the TextBox.

IIf(Fields.myBoolean,'YES','NO')

Regards
Erwin
0
Ricardo
Top achievements
Rank 1
answered on 03 Apr 2013, 05:46 PM
Thank you Erwin, IT's working now! :D
0
Dave
Top achievements
Rank 1
answered on 15 Nov 2013, 11:06 AM
Can you do this for a 1 or 0 bit field as well.
0
Squall
Top achievements
Rank 1
answered on 15 Nov 2013, 04:04 PM
Have you tried to use IIF function with bit data fields? If it doesn't work out of the box try with conversion function =IIF(CBool(Fields.MyField),'YES','NO')

SN
Tags
Report Designer (standalone)
Asked by
Ricardo
Top achievements
Rank 1
Answers by
erwin
Top achievements
Rank 1
Veteran
Ricardo
Top achievements
Rank 1
Dave
Top achievements
Rank 1
Squall
Top achievements
Rank 1
Share this question
or