BusinessObject Relations

Stimulsoft Reports.WPF discussion
Post Reply
AlexN
Posts: 11
Joined: Wed Feb 01, 2012 9:45 am

BusinessObject Relations

Post by AlexN »

Hello,

i'm using a Business Object named Context with this relations:
Context : Employee = * : 1
Employee : Customer = * : 1

Know i have the text "{Context.Employee.Customer.Name}". When i register only one object to the Report it works fine, but with two or more objects i have the problem, that all objects have the same customer.name - from the first object.

Am I doing something wrong or is this a bug?

Thank you for your help!
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

BusinessObject Relations

Post by HighAley »

Hello.
AlexN wrote:i'm using a Business Object named Context with this relations:
Context : Employee = * : 1
Employee : Customer = * : 1

Know i have the text "{Context.Employee.Customer.Name}". When i register only one object to the Report it works fine, but with two or more objects i have the problem, that all objects have the same customer.name - from the first object.

Am I doing something wrong or is this a bug?

Thank you for your help!
You should run next method after registering Business Object

Code: Select all

rep.Dictionary.SynchronizeBusinessObjects(3);
3 is a nested level.

Thank you.
AlexN
Posts: 11
Joined: Wed Feb 01, 2012 9:45 am

BusinessObject Relations

Post by AlexN »

When I run this method without nested level nothing happens, but with nested level an error appers:
"user-defined type : member names cannot be the same as their enclosing type "
And also i dont know the nested level of the businessobjects because i use the same command for different reports with diffrent nested levels.
Thank you!
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

BusinessObject Relations

Post by HighAley »

Hello.
AlexN wrote:When I run this method without nested level nothing happens, but with nested level an error appers:
"user-defined type : member names cannot be the same as their enclosing type "
And also i dont know the nested level of the businessobjects because i use the same command for different reports with diffrent nested levels.
Please, send a sample project which reproduce your issue for analysis.

Thank you.
AlexN
Posts: 11
Joined: Wed Feb 01, 2012 9:45 am

BusinessObject Relations

Post by AlexN »

Problem solved, I must use a Databand for each relation instead of one global.
Andrew
Posts: 4108
Joined: Fri Jun 09, 2006 3:58 am

BusinessObject Relations

Post by Andrew »

Great!

Have a good day!
Thank you.
Post Reply