Chr()

Stimulsoft Reports.NET discussion
Post Reply
whythetorment
Posts: 20
Joined: Fri Nov 20, 2009 7:40 am

Chr()

Post by whythetorment »

Hi,

How can I display chr(168) and chr(254). If you change the font to Windings it displays either a ticked box or an empty box.

Depending on my criteria, it must be either of these e.g. ToString(IIF(DataSource1.ReqDrvLic.ToString() == "1",chr(168),chr(254)))

Thanks
Ivan
Posts: 960
Joined: Thu Aug 10, 2006 1:37 am

Chr()

Post by Ivan »

Hello,

Please use the following expression for C#:

Code: Select all

{IIF(your_condition, (char)168, (char)254)}
or the following expression for VB:

Code: Select all

{IIF(your_condition, ChrW(168), ChrW(254))}
Thank you.
fadliwdt
Posts: 6
Joined: Mon Mar 12, 2012 2:13 am
Location: ID

Chr()

Post by fadliwdt »

I try.. but why the ouput error
C:\Users\fadliwdt\AppData\Local\Temp\5x4pphuz.0.vb(1589,0) : error BC30108: 'Char' is a type and cannot be used as an expression.C:\Users\fadliwdt\AppData\Local\Temp\5x4pphuz.0.vb(1589,0) : error BC30287: '.' expected.
Ivan
Posts: 960
Joined: Thu Aug 10, 2006 1:37 am

Chr()

Post by Ivan »

Hello,

It seems that you have chosen VB language in the report.
Therefore please use the following expression for VB:

Code: Select all

{IIF(your_condition, ChrW(168), ChrW(254))}
Thank you.
Post Reply