Hide (Invisible) TextBox in ReportViewer if empty (null) in ASP.Net

phonghue
 
on Nov 10, 2021 08:18 PM
1336 Views

Hello,

Set Textbox Visible and Invisible on the Report

I have an input form with 16 textboxes.  Look like this.

Type                      Description      Total Grade

Textbox1               Textbox1          Textbox1

Textbox2               Textbox2          Textbox2

Textbox3               Textbox3          Textbox3

And so on until 16 of them.

I will build the report that will have the output for these data textbox.

not all the 16 textboxes that will have data.  Some of them will be empty. 

So, it is possible to build the report that only shows the textbox that have data and not showing the textbox that have no data.

My point is I don’t want the empty textbox show on the report.  If only 5 or 6 textbox have data, then show only 5 or 6.  Not 16.

Please help.

Thanks.

Download FREE API for Word, Excel and PDF in ASP.Net: Download
dharmendr
 
on Nov 10, 2021 08:21 PM

Use expression for each TextBox.

=iif(Fields!YouField.Value = "0", false, true)