How to change width of text controls in a data band at runtime?
Posted: Tue Apr 20, 2010 7:41 am
Hi,
I need help with conditional formatting.
I have a report with a data band. The data band contains several text controls per row, for example like this:
Now I need to do the following:
depending on a value in the data source, I need to change the width of some fields in some rows.
For example, if the datasource has 20 rows and the special value in row 14 says "make Field 2 wider", then I want to change the fields only in this row, so they look like that:
--> Field 2 is wider than before and Field 3 is disabled in order to make room for Field 2.
The other rows should stay as they are (so they still look like the first example).
There are different possibilities which field has to become wider and which field(s) have to be disabled in order to make room for the wider field, and they can all occur in the same report.
I know how to edit "normal" controls in a designer generated report at runtime, but I don't know how to iterate through each row of a data band.
Or is this somehow possible via conditions?
Thank you!
I need help with conditional formatting.
I have a report with a data band. The data band contains several text controls per row, for example like this:
Code: Select all
| Field 1 | Field 2 | Field 3 | Field 4 |depending on a value in the data source, I need to change the width of some fields in some rows.
For example, if the datasource has 20 rows and the special value in row 14 says "make Field 2 wider", then I want to change the fields only in this row, so they look like that:
Code: Select all
| Field 1 | Field 2 | Field 4 |The other rows should stay as they are (so they still look like the first example).
There are different possibilities which field has to become wider and which field(s) have to be disabled in order to make room for the wider field, and they can all occur in the same report.
I know how to edit "normal" controls in a designer generated report at runtime, but I don't know how to iterate through each row of a data band.
Or is this somehow possible via conditions?
Thank you!