drees727
asked on
ASP.NET 2.0 / Nested Gridview / Function Question
I'm using a nested gridview (idea from: http://programmers.wordpress.com/2006/07/26/nested-gridview-to-show-masterdetails-relationship-in-aspnet-20/). My nested gridview contains the following:
<asp:GridView ID="Gridview2" runat="server" DataSource="<%#GetNames(Co nvert.ToIn t32(Eval(" ID"))) %>"
I need to create a function that creates a datatable so each time a row is bound to the main gridview, the child gridview is also bound with the corresponding values. I'm using Access as my database and my nested gridview select command looks something like:
SelectCommand="SELECT Table2.[Name], [Table2].[ChildID] FROM Table2 Where [Table2].[ChildID] = [Table1].[ID]
How do I use VB to create the GetNames function (below) to get this to work? Thanks for your help!!
************************** ********** ********** ********** ********** ****
Public Function GetNames() As DataTable
End Function
<asp:GridView ID="Gridview2" runat="server" DataSource="<%#GetNames(Co
I need to create a function that creates a datatable so each time a row is bound to the main gridview, the child gridview is also bound with the corresponding values. I'm using Access as my database and my nested gridview select command looks something like:
SelectCommand="SELECT Table2.[Name], [Table2].[ChildID] FROM Table2 Where [Table2].[ChildID] = [Table1].[ID]
How do I use VB to create the GetNames function (below) to get this to work? Thanks for your help!!
**************************
Public Function GetNames() As DataTable
End Function
ASKER
AccessDataSource
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Bob