S
Sarmatia
I have a table of ID vaules that are related to lookup tables.
I created a DataAccess component from wich the ObjectDataSource gets a
typed datatable. A GridView is bound to that ObjectDataSource and
allows Edit and Delete.
On the same page is the means to add a new record (since the GridView
does not support that ... but that's another rant) via several
DropDownLists bound to other ObjectDataSources.
The issue now is, what is the best way to display the lookup values in
the table? Options are:
1) Return the lookup values with the typed datatable. This seems to
unnecessarily link the table with which I want to interact to the
lookup tables.
2) Use the value from the main table to get the values form the
ObjectDataSources that are already on the page. This seems like "the
right way to do it" but how? I can't bind the Labels in the GridView to
anything but the fields in the tabe to which that is bound. Do I have
to add a DropDownList to get the lookup value then use that for the
label? (I don't want to display a drop down list if it's not meant to
be edited)
Any advice would be much appreciated.
I created a DataAccess component from wich the ObjectDataSource gets a
typed datatable. A GridView is bound to that ObjectDataSource and
allows Edit and Delete.
On the same page is the means to add a new record (since the GridView
does not support that ... but that's another rant) via several
DropDownLists bound to other ObjectDataSources.
The issue now is, what is the best way to display the lookup values in
the table? Options are:
1) Return the lookup values with the typed datatable. This seems to
unnecessarily link the table with which I want to interact to the
lookup tables.
2) Use the value from the main table to get the values form the
ObjectDataSources that are already on the page. This seems like "the
right way to do it" but how? I can't bind the Labels in the GridView to
anything but the fields in the tabe to which that is bound. Do I have
to add a DropDownList to get the lookup value then use that for the
label? (I don't want to display a drop down list if it's not meant to
be edited)
Any advice would be much appreciated.