Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
155
No Data Showing in WHDG
posted

Trying to put together a proof-of-concept using the Trial Version of 2009.2.  Created a new web page and added an ObjectDataSource, WebHierarchicalDataSource, and WebHierarchicalDataGrid to the page and configured following the examples in the QuickStart video and the WSDG Sample, but not data is shown when the page is run.

The proper column headers appear, and a test of the method that returns the strongly-typed collection verifies that it is retrieving and populating the collection with data, but nothing shows up on the page.

This is an example for a self-referencing data set.  Here is the code from the page.

  <asp:ScriptManager ID="ScriptManager1" runat="server">
  </asp:ScriptManager>  

<ig:WebHierarchicalDataGrid ID="WebHierarchicalDataGrid1" runat="server"
   AutoGenerateBands="False" AutoGenerateColumns="False"
   DataKeyFields="NamespaceID" DataMember="odsNamespaceList_DefaultView"
   DataSourceID="whds" Height="350px" IsSelfReference="True"
   Key="odsNamespaceList_DefaultView" Width="400px">

   <Columns>
    <ig:BoundDataField DataFieldName="NamespaceID" Key="NamespaceID">
     <Header Text="NamespaceID" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="ParentID" Key="ParentID">
     <Header Text="ParentID" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="ShortName" Key="ShortName">
     <Header Text="ShortName" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="DisplayName" Key="DisplayName">
     <Header Text="DisplayName" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="FeaturePath" Key="FeaturePath">
     <Header Text="FeaturePath" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="InheritsFromParent" Key="InheritsFromParent">
     <Header Text="InheritsFromParent" />
    </ig:BoundDataField>
   </Columns>

   <Bands>
    <ig:Band DataMember="odsNamespaceList_DefaultView" ShowFooter="false" ShowHeader="false" IsSelfReference="true" AutoGenerateColumns="false">

     <Columns>
    <ig:BoundDataField DataFieldName="NamespaceID" Key="NamespaceID">
     <Header Text="NamespaceID" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="ParentID" Key="ParentID">
     <Header Text="ParentID" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="ShortName" Key="ShortName">
     <Header Text="ShortName" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="DisplayName" Key="DisplayName">
     <Header Text="DisplayName" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="FeaturePath" Key="FeaturePath">
     <Header Text="FeaturePath" />
    </ig:BoundDataField>
    <ig:BoundDataField DataFieldName="InheritsFromParent" Key="InheritsFromParent">
     <Header Text="InheritsFromParent" />
    </ig:BoundDataField>
     </Columns>

    </ig:Band>
   </Bands>
</ig:WebHierarchicalDataGrid>

  <ig:WebHierarchicalDataSource ID="whds" runat="server">
   <DataRelations>
    <ig:DataRelation ChildColumns="ParentID" ChildDataViewID="odsNamespaceList_DefaultView"
     ParentColumns="NamespaceID" ParentDataViewID="odsNamespaceList_DefaultView" />
   </DataRelations>
   <DataViews>
    <ig:DataView ID="odsNamespaceList_DefaultView" DataMember="DefaultView"
     DataSourceID="odsNamespaceList" />
   </DataViews>
  </ig:WebHierarchicalDataSource>

  <asp:ObjectDataSource ID="odsNamespaceList" runat="server"
   SelectMethod="GetNamespaceList" TypeName="Test.BLL.TestDataGenerator">
  </asp:ObjectDataSource>

It seems like I must be missing something simple, but darned if I can figure out what it is.

Parents Reply Children
No Data