ObjectDataSource and ChildObjects

M

michaelkb

Has anyone bound a control to an ObjectDataSource when the main object
had a child object? I have a BillingObject with a a child object called
AddressObject. I can't figure out how to create a BoundField for
anything in the AddressaObject. I tried this with no luck:

OwnerID is a property of the main BillingObject, so this works fine:
<asp:BoundField DataField="OwnerID" HeaderText="OwnerID"
SortExpression="OwnerID" />

State is a property of the BillingAddress object within the
BillingObject. The below does not work:
<asp:BoundField DataField="BillingAddress.State" HeaderText="State"
SortExpression="BillingAddress.State" />

Any ideas?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,802
Messages
2,569,662
Members
45,433
Latest member
andrewartemow

Latest Threads

Top