I am trying to create reports.
I'd like for example to attach my Invoice BO to an invoice report in WInForms using the report viewer control.
seems like the parent Invoice BO works fine.
but the child details connection BO never displays.
I am looking at samples from Here: http://www.gotreportviewer.com/
that help but do not get me what I want.
can anyone say for sure if this is possible or not ?
I think it may just be a question of setting the right properties....
for now I guess I'll do a proc that sends out flat data or 2 tables of data as they work...
but that just seems so WRONG!!!
ajj3085:Oh.. you need to have a list control which contains the textboxes for the child elements.
I am trying to use a table for the details.... so far no dice.
I do have two sources, that's all good.
but the child table just stays empty.
if I try and nest the table in a list it freaks out and whines about the settings.
Hmmmm...
I know this should work! ( I Guess ? )
SOLVED!
Ok here is the lowdown: you have to bind to the report differently than when you bind to a form!
say you have a BO that you show a master and then a gridview ...
when you put the master on the form you get 2 binding sources and you can set them like:
ChildBindingSource.DataSource = ParentBindingSource
ParentBindingSource.DataSource = ActEdit
and the grid fills in with the child rows.
with a winforms local report that will not work!
has to be like:
ChildBindingSource.DataSource = ActEdit.DetailsCollection
ParentBindingSource.DataSource = ActEdit
Copyright (c) Marimer LLC