I want to add a custom row number on databand without using the system variable Line.
If I met a certain condition e.g if ID is divisible by 2 then the row number will increment.
Row Number
Re: Row Number
Hi Jaynner,
Please open the attached report in our online demo http://demo.stimulsoft.com/#Net/SimpleList or in Viewer.exe which comes with a standard installation package.
There I created a variable v1i the report's Dictionary and in the BeforePrint event of the DataBand1 I added the following;
Thank you,
Edward
Please open the attached report in our online demo http://demo.stimulsoft.com/#Net/SimpleList or in Viewer.exe which comes with a standard installation package.
There I created a variable v1i the report's Dictionary and in the BeforePrint event of the DataBand1 I added the following;
Code: Select all
if (Customers.CompanyName[0] == 'A' || Customers.CompanyName[0] == 'B')
{
v1 = v1 + 1;
}
Edward
Re: Row Number
Thank you very much edward. How do I find the BeforePrint event?Edward wrote: ↑Thu May 31, 2018 5:18 am Hi Jaynner,
Please open the attached report in our online demo http://demo.stimulsoft.com/#Net/SimpleList or in Viewer.exe which comes with a standard installation package.
There I created a variable v1i the report's Dictionary and in the BeforePrint event of the DataBand1 I added the following;DataBand1_BeforePrint.pngCode: Select all
if (Customers.CompanyName[0] == 'A' || Customers.CompanyName[0] == 'B') { v1 = v1 + 1; }
BeforePrintDataBand1.mrt
Thank you,
Edward
Re: Row Number
Hi Jaynner,
No problem at all, please check some similar steps in the video of using the 'Click' Event in the Windows Forms application as follows;
https://www.youtube.com/watch?v=3BfDdBR6TFE
You could find the BeforePrint event in the exact same way in the web-based designer if you would like to follow the live demo in the following link;
http://demo.stimulsoft.com/#Net/SimpleList
Then please click Edit button on the right-hand side to enter the designer of the displayed report.
To open the attached above report template there, go to File-Open-Browse and select the BeforePrintDataBand1.mrt file there.
Also, you could check the report component names, assigned events and the report structure in the Report Tree:
https://www.stimulsoft.com/en/documenta ... t_tree.htm
Once you have an idea about the report structure, the easiest way to access the components and their properties and events by using the Property Editor as in the video I mentioned above.
Please do let us know if you need any help.
Thank you,
Edward
No problem at all, please check some similar steps in the video of using the 'Click' Event in the Windows Forms application as follows;
https://www.youtube.com/watch?v=3BfDdBR6TFE
You could find the BeforePrint event in the exact same way in the web-based designer if you would like to follow the live demo in the following link;
http://demo.stimulsoft.com/#Net/SimpleList
Then please click Edit button on the right-hand side to enter the designer of the displayed report.
To open the attached above report template there, go to File-Open-Browse and select the BeforePrintDataBand1.mrt file there.
Also, you could check the report component names, assigned events and the report structure in the Report Tree:
https://www.stimulsoft.com/en/documenta ... t_tree.htm
Once you have an idea about the report structure, the easiest way to access the components and their properties and events by using the Property Editor as in the video I mentioned above.
Please do let us know if you need any help.
Thank you,
Edward
Re: Row Number
You are so kind. Thank you very much.Edward wrote: ↑Thu Jun 07, 2018 7:41 am Hi Jaynner,
No problem at all, please check some similar steps in the video of using the 'Click' Event in the Windows Forms application as follows;
https://www.youtube.com/watch?v=3BfDdBR6TFE
You could find the BeforePrint event in the exact same way in the web-based designer if you would like to follow the live demo in the following link;
http://demo.stimulsoft.com/#Net/SimpleList
Then please click Edit button on the right-hand side to enter the designer of the displayed report.
To open the attached above report template there, go to File-Open-Browse and select the BeforePrintDataBand1.mrt file there.
Also, you could check the report component names, assigned events and the report structure in the Report Tree:
https://www.stimulsoft.com/en/documenta ... t_tree.htm
Once you have an idea about the report structure, the easiest way to access the components and their properties and events by using the Property Editor as in the video I mentioned above.
Please do let us know if you need any help.
Thank you,
Edward
-
- Posts: 6263
- Joined: Tue Mar 20, 2018 5:34 am
Re: Row Number
Hello
We are always glad to help you!
Please let us know if you need any additional help.
Thank you.
We are always glad to help you!
Please let us know if you need any additional help.
Thank you.