Hi all,
I'm trying to build a report where the number of rows will be calculated according to a field (from the DB) containing a number.
If this field contains the number 3, then 3 rows will be created. The numbers 1, 2 and 3 will be visible in the corresponding rows.
If the field contains 10, 10 rows will be created. The numbers 1, 2... to 10 will be visible in the corresponding rows.
How can I do this?
I've been searching in the databand property box but could find something which helps.
Thanks a lot,
Jennifer.
Number of rows depending on a certain field
Number of rows depending on a certain field
Hi Jennifer,
In the BeforePrintEvent of the attached report the following code has been used:
for counting of lines it is very convenient to use Line function.
Thank you.
In the BeforePrintEvent of the attached report the following code has been used:
Code: Select all
Data1.CountData = Categories.Count;
Thank you.
Number of rows depending on a certain field
But it's not about counting lines, maybe I wasn't clear enough. I have this:
name | address | articles
Name1 address1 3
1
2
3
Name2 address2 5
1
2
3
4
5
Is it clearer? I want to create as many rows as the number in my field "articles"
Thanks a lot
name | address | articles
Name1 address1 3
1
2
3
Name2 address2 5
1
2
3
4
5
Is it clearer? I want to create as many rows as the number in my field "articles"
Thanks a lot
Number of rows depending on a certain field
Please see the report in the attachment and BeforePrintEvent of the DataBand.
MasterDataBand.PrintIfDetailEmpty must be set in true.
Thank you.
MasterDataBand.PrintIfDetailEmpty must be set in true.
Thank you.
- Attachments
-
- 157.CountDataProperty.mrt
- (16.71 KiB) Downloaded 330 times
Number of rows depending on a certain field
Thanks a lot Edward, it is working perfectly.