Click here to Skip to main content
15,891,943 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have a dynamic data entities web site and added a ado data entity model. That work fine. But I am try to do a custom page with two tables that have a parent child relationship. I am trying to follow the directions in the link be low. But get an error when I try to display the parent table in a grid view. I get the error below. I have included my markup.

CSS
https://msdn.microsoft.com/en-us/library/vstudio/dd985039(v=vs.100).aspx

Could not determine a MetaTable. A MetaTable could not be determined for the data source 'LinqDataSource1' and one could not be inferred from the request URL. Make sure that the table is mapped to the data source, or that the data source is configured with a valid context type and table name, or that the request is part of a registered DynamicDataRouteCould not determine a MetaTable. A MetaTable could not be determined for the data source 'LinqDataSource1' and one could not be inferred from the request URL. Make sure that the table is mapped to the data source, or that the data source is configured with a valid context type and table name, or that the request is part of a registered DynamicDataRoute



<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
        <asp:DynamicDataManager ID="DynamicDataManager1" runat="server">
            <datacontrols>
                <asp:DataControlReference ControlID="GridView1" />
            </datacontrols>
        
        <br />
        <asp:LinqDataSource ID="LinqDataSource1" runat="server" ContextTypeName="InspectionsEntities" EntityTypeName="" TableName="tbl_lat_video_inspect_header">
        
        <br />
        <asp:GridView ID="GridView1" runat="server" AllowPaging="True" DataSourceID="LinqDataSource1" SelectedIndex="1" AutoGenerateColumns="True">
            <columns>
                <asp:CommandField ShowSelectButton="True" />
            </columns>
        
        <br />
    
    </div>
    </form>
</body>
</html>
Posted
Comments
John C Rayan 7-Aug-15 15:32pm    
Hi your markup is incomplete

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900