If I understand what you are asking you just want to edit a table using a GridView and are wondering what object types to use. In my experience the most common example of editing a collection with a grid is an example like an order. The root object is the order and the child collection are the order line items. Your root object uses a stored procedure, let's call it GetOrder to retrieve the order and line items from the data base and returns two result sets. The first result set is the order the second result set are the line items. In the Data Access region in the DataPortal_Fetch method of the Order class the first result set is retrieved via a datareader and populates the order properties with the information from the order row. Then the next result set is processed via the EditableChild collection class and the the Editable Child to poplulate the line item collection.
In your example I would do exactly the same thing except the the stored procedure would return only one result set which would be used to populate the Family collection. The root object, let's call it mFamily would not retrieve any data from the database and it would have only one property lets say it is named FamilyRecords. In my form I would then instantiate the EditableRoot class mFamily and bind my GridView to mFamily.FamilyRecords. The only purpose of the root object in this case is to host the collection. I hope this helps
If I understand correctly, you have a small table and you just want to allow the user to edit the data in that table - pretty much directly. No parent-child, nothing complex?
This is the Admin\Role and Admin\Roles classes in the ProjectTracker sample, and the associated RoleEdit.aspx page. Roles is an editable root collection, containing editable child objects.
Copyright (c) Marimer LLC