Starting with business objects
Posted: Fri Oct 31, 2014 8:26 am
Hi
We are building a new application that will be linked to Stimulsoft.
I created a template for our first try. It consists in printing a/several list of seed lots, with information about their pedigree, the number of seeds to use, etc.
In this template, I manually created a business object and all the columns that I need.
A C# code is making the link between the query and the business object, via a collection of objects with the same names as my columns.
Here is a simplified version of the model: To display data coming from LIST, LOT_IN_LIST and LOT, no problem, it works perfectly. The designer looks like this (please scroll on the right): Now, I want to retrieve characteristics of the lots. For example, a characteristic is "germination rate". In the table lot_characteristics, we would have the value "99" for "lot1" and "germination rate".
Each user can choose the characteristics he would like to display by defining a layout profile. A layout profile contain several characteristics.
The users will choose the profile in the report filters, so the characteristics retrieved by the query will never be the same.
And I don't know how to manage this...
I thought about creating a set of 30 default characteristic columns, in the business objects: characteristic1_name, characteristic1_value, characteristic2_name, characteristic2_value, etc... But if the profile has only 5 characteristics then I have 25 columns for nothing. Plus it's not dynamic. Each time the user add a characteristic to a profile, he would have to add the corresponding component on the designer.
Then I thought about crosstabs.
I defined a child business object: and placed a crosstab in a panel: - What I'm missing here, is how to define a relation between the 2 business object? How do I tell that the link in between them is on the LotID ?
- Second problem: the headers of the crosstab will be repeated for each lot of the list. This is not what I want, I would like the headers to be displayed only once, at the top of the page, in the GroupHeaderBand or at least at the same level. How can I do? (Similar problem as in this topic).
Do you see any other solution?
Thank you and sorry for this looooon post!
We are building a new application that will be linked to Stimulsoft.
I created a template for our first try. It consists in printing a/several list of seed lots, with information about their pedigree, the number of seeds to use, etc.
In this template, I manually created a business object and all the columns that I need.
A C# code is making the link between the query and the business object, via a collection of objects with the same names as my columns.
Here is a simplified version of the model: To display data coming from LIST, LOT_IN_LIST and LOT, no problem, it works perfectly. The designer looks like this (please scroll on the right): Now, I want to retrieve characteristics of the lots. For example, a characteristic is "germination rate". In the table lot_characteristics, we would have the value "99" for "lot1" and "germination rate".
Each user can choose the characteristics he would like to display by defining a layout profile. A layout profile contain several characteristics.
The users will choose the profile in the report filters, so the characteristics retrieved by the query will never be the same.
And I don't know how to manage this...
I thought about creating a set of 30 default characteristic columns, in the business objects: characteristic1_name, characteristic1_value, characteristic2_name, characteristic2_value, etc... But if the profile has only 5 characteristics then I have 25 columns for nothing. Plus it's not dynamic. Each time the user add a characteristic to a profile, he would have to add the corresponding component on the designer.
Then I thought about crosstabs.
I defined a child business object: and placed a crosstab in a panel: - What I'm missing here, is how to define a relation between the 2 business object? How do I tell that the link in between them is on the LotID ?
- Second problem: the headers of the crosstab will be repeated for each lot of the list. This is not what I want, I would like the headers to be displayed only once, at the top of the page, in the GroupHeaderBand or at least at the same level. How can I do? (Similar problem as in this topic).
Do you see any other solution?
Thank you and sorry for this looooon post!