i m using WebHierarchicalDataGrid, i have bind dataset but data is not appearing in the grid
this is my code
---Vb
Imports eReport_BusinessLayerImports Infragistics.Web.UI.GridControls
Public Class _Default Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim x As New Testing.PatTPTableAdapters.PageSizeTableAdapter Dim x1 As New Testing.PatTPTableAdapters.TestDetailsTableAdapter Dim x2 As New Testing.PatTP x.Fill(x2.PageSize) x1.Fill(x2.TestDetails)
Me.WebHierarchicalDataGrid3.DataSource = x2 Me.WebHierarchicalDataGrid3.DataBind()
End SubEnd Class
--aspx
<ig:WebHierarchicalDataGrid ID="WebHierarchicalDataGrid3" runat="server" AutoGenerateBands="False" AutoGenerateColumns="False" DataKeyFields="RtPageSize" Height="350px" Key="PageSize" StyleSetName="IG" Width="905px" > <Bands> <ig:Band AutoGenerateColumns="False" Key="TestDetails" DataKeyFields="RtPageSize"> <Columns> <ig:BoundCheckBoxField DataFieldName="SelectTP" Key="SelectTP" Width="25px"> </ig:BoundCheckBoxField> <ig:BoundDataField DataFieldName="RtPageSize" Key="RtPageSize" Hidden="True"> <Header Text="RtPageSize" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="TestName" Key="TestName"> <Header Text="TestName" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="SampleStatus" Key="SampleStatus"> <Header Text="SampleStatus" /> </ig:BoundDataField> </Columns> </ig:Band> </Bands>
<Columns> <ig:TemplateDataField Key="Print Report" Width="90px"> <ItemTemplate> <igtxt:WebImageButton ID="WebImageButton1" runat="server" Height="20px" Text="Print Report" UseBrowserDefaults="False" Width="81px"> <RoundedCorners DisabledImageUrl="[ig_butXP5wh.gif]" FocusImageUrl="[ig_butXP3wh.gif]" HoverImageUrl="ig_butCRM2.gif" ImageUrl="ig_butCRM1.gif" MaxHeight="40" MaxWidth="400" PressedImageUrl="ig_butCRM2.gif" RenderingType="FileImages" HeightOfBottomEdge="2" WidthOfRightEdge="2" /> <Appearance>
Please help me
Hello rajan_kajrolkar,
Let me know if you need further assistance.
In the code showed in your message the configuration of the grid appears correct and you are binding the grid on “Page_Load” event which is also correct.
What cannot be seen in the code is the way that the Data Source for the grid id generated and the actual type of this Data Source. I can see that business objects are used for creating the Data Source.
The supported Data Source types for the grid are shown here - http://help.infragistics.com/Help/NetAdvantage/ASPNET/2011.2/CLR4.0/html/WebHierarchicalDataGrid_About_Data_Binding.html
If your object does not return the data for the grid in one of these formats the grid data may not be displayed correctly.
You can also use our “WebHierarchicalDataSource” to create the Data Source for the grid - http://help.infragistics.com/Help/NetAdvantage/ASPNET/2011.1/CLR4.0/html/WebGrid_Binding_WebGrid_to_a_WebHierarchicalDataSource.html
Inform me if you have additional questions.