Hello,
I am trying to follow the tutorial at http://demos.telerik.com/aspnet-ajax/grid/examples/dataediting/threelevel/defaultcs.aspx
Below is the applicable code as to where I think the issue may be. Anyone have any ideas why the grid does not even display any data when I load the page.
I am trying to follow the tutorial at http://demos.telerik.com/aspnet-ajax/grid/examples/dataediting/threelevel/defaultcs.aspx
Below is the applicable code as to where I think the issue may be. Anyone have any ideas why the grid does not even display any data when I load the page.
<telerik:RadScriptManager ID="RadScriptManager1" runat="server"></telerik:RadScriptManager><telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> <AjaxSettings> <telerik:AjaxSetting AjaxControlID="RadGridSmears"> <UpdatedControls> <telerik:AjaxUpdatedControl ControlID="RadGridSmears"></telerik:AjaxUpdatedControl> </UpdatedControls> </telerik:AjaxSetting> </AjaxSettings></telerik:RadAjaxManager><telerik:RadGrid ID="RadGridSmears" runat="server" CellSpacing="0" DataSourceID="SqlDataSourceSmears" ShowStatusBar="True" AutoGenerateColumns="False" PageSize="3" AllowSorting="True" AllowPaging="True" GridLines="None" AllowAutomaticDeletes="True" AllowAutomaticUpdates="True" OnItemUpdated="RadGridSmears_ItemUpdated" OnItemDeleted="RadGridSmears_ItemDeleted"> <PagerStyle Mode="NumericPages"></PagerStyle> <MasterTableView DataSourceID="SqlDataSourceSmears" DataKeyNames="SampleNo" AllowMultiColumnSorting="True" Width="100%" CommandItemDisplay="Top" Name="Smears"> <DetailTables> <telerik:GridTableView DataKeyNames="AnalysisNo" DataSourceID="SqlDataSourceAnalysis" Width="100%" runat="server" CommandItemDisplay="Top" Name="Analysis"> <ParentTableRelation> <telerik:GridRelationFields DetailKeyField="SampleNo" MasterKeyField="SampleNo"> </telerik:GridRelationFields> </ParentTableRelation>
...blah...blah<asp:SqlDataSource ID="SqlDataSourceAnalysis" runat="server" ConnectionString="<%$ ConnectionStrings:XConnectionString %>" DeleteCommand="DELETE FROM [Analysis] WHERE [AnalysisNo] = @AnalysisNo AND [AnalysisDateTime]=@AnalysisDateTime" SelectCommand="SELECT * FROM [Analysis] WHERE [SampleNo] = @SampleNo" UpdateCommand="UPDATE [Analysis] SET [AnalysisDateTime] = @AnalysisDateTime, [AlphaCPM] = @AlphaCPM, [BetaCPM] = @BetaCPM, [InstrumentIDAlpha] = @InstrumentIDAlpha WHERE [AnalysisNo] = @AnalysisNo"> <SelectParameters> <asp:Parameter Name="SampleNo" Type="String"></asp:Parameter> </SelectParameters> <DeleteParameters> <asp:Parameter Name="AnalysisNo" Type="Int32"></asp:Parameter> <asp:Parameter Name="AnalysisDateTime" Type="DateTime"></asp:Parameter> </DeleteParameters> <UpdateParameters> <asp:Parameter Name="AnalysisDateTime" Type="DateTime"></asp:Parameter> <asp:Parameter Name="AlphaCPM" Type="Int32"></asp:Parameter> <asp:Parameter Name="BetaCPM" Type="Int32"></asp:Parameter> <asp:Parameter Name="InstrumentIDAlpha" Type="String"></asp:Parameter> <asp:Parameter Name="AnalysisNo" Type="Int32"></asp:Parameter> </UpdateParameters></asp:SqlDataSource><asp:SqlDataSource ID="SqlDataSourceSmears" runat="server" ConnectionString="<%$ ConnectionStrings:XConnectionString %>" DeleteCommand="DELETE FROM [Smears] WHERE [SampleNo] = @SampleNo" SelectCommand="SELECT * FROM [Smears] WHERE [SampleNo] = @SampleNo" UpdateCommand="UPDATE [Smears] SET [Station] = @Station, [SampleDate] = @SampleDate, [BagNo] = @BagNo WHERE [SampleNo] = @SampleNo"> <SelectParameters> <asp:Parameter Name="SampleNo" Type="String"></asp:Parameter> </SelectParameters> <DeleteParameters> <asp:Parameter Name="SampleNo" Type="String"></asp:Parameter> </DeleteParameters> <UpdateParameters> <asp:Parameter Name="Station" Type="String"></asp:Parameter> <asp:Parameter Name="SampleDate" Type="DateTime"></asp:Parameter> <asp:Parameter Name="BagNo" Type="Int32"></asp:Parameter> <asp:Parameter Name="SampleNo" Type="String"></asp:Parameter> </UpdateParameters></asp:SqlDataSource>