none
Displaying boolean values as radiobutton RRS feed

  • Question

  • hi,all
      this expression (= iif( Fields!absent.Value , Chr(82), Chr(84))  --- with a wingdings 2 ) display a checkbox in report
     i want to know if there is an expression like this to display a radiobutton in a report
    thanks
    Sunday, August 23, 2009 8:57 AM

Answers

  • The problem with using Wingdings is they won't render in Firefox (or Opera, AFAIK)

    My solution is to create small images and embed them in the RDLC, then put an image field in the Table column and set it to use an Embedded Source.

    You can then set the Value property for the Image as follows:

    =iif( Fields!Enabled.Value , "greentick", "redcross")

    The above chooses the greentick or redtick image depending on the value of the Enabled Boolean field.

    The quotes around the image names are important and must be included.

    It should be noted that I am using a Business Object data source (not SQL/Relational) via Castle ActiveRecord, but I can't see that there would be any difference with using a SQL source.
    Friday, August 28, 2009 11:22 AM

All replies

  • Hi,
    You might want to look up the ASCII code for it.  http://www.knowlesys.com/software/glyph-font-viewer/
    Check out Wingdings 161-164.


    Stella Chan
    Program Manager
    SQL Server Reporting Services

    -------
    This info is provided as-is with no warranty.

    • Proposed as answer by StellaC - MSFT Tuesday, August 25, 2009 4:51 AM
    Tuesday, August 25, 2009 4:50 AM
  • hi,  
      thd code Chr(161), Chr(164))  worked and a radiobutton appeaed, but i want to display RadioButtonlist contains 3 radiobuttons. the report will select the right radiobutton depend on the value in the database.
    Ex: if the radiobutton list contains (Good   VeryGood   Excellent) and the current record in the report is Good, i want the value Good in the radioButtonlist in the report to be selected. is it possible in the LocalReport????????????

    thanks
    Wednesday, August 26, 2009 11:39 AM
  • The problem with using Wingdings is they won't render in Firefox (or Opera, AFAIK)

    My solution is to create small images and embed them in the RDLC, then put an image field in the Table column and set it to use an Embedded Source.

    You can then set the Value property for the Image as follows:

    =iif( Fields!Enabled.Value , "greentick", "redcross")

    The above chooses the greentick or redtick image depending on the value of the Enabled Boolean field.

    The quotes around the image names are important and must be included.

    It should be noted that I am using a Business Object data source (not SQL/Relational) via Castle ActiveRecord, but I can't see that there would be any difference with using a SQL source.
    Friday, August 28, 2009 11:22 AM