Hi there, i create a WebHierarchicalDataGrid and when i try to expand a row i get this error message:
Can someone tell me what can i do to prevent this error?
Hello,
Thank you for posting in the Infragistics community !
I would need you to provide more information on your scenario and configuration in order to reproduce and investigate this error. In order to do so please provide the following answers:
- the version of .NetAdvantage that you are using
- the configuration of the grid - the markup or code behind, is it fully bound initially..etc. However it will be best if you can provide the whole markup and code behind for the grid or a working sample demonstrating this issue
- on which line does the error occur ?
Looking forward to hearing from you.
Do you need the stored procedure ?
I there,
the grid code is this one:
<asp:Content ID="Content3" ContentPlaceHolderID="MainContentPlaceHolder" runat="server">
<ig:WebHierarchicalDataGrid ID="WebHierarchicalDataGrid1" runat="server" AutoGenerateColumns="False" Height="100%" Width="100%" DataSourceID="WebHierarchicalDataSource1" DataKeyFields="cvestamp" OnInit="WebHierarchicalDataGrid1_Init" Key="nome"> <Columns> <ig:BoundDataField DataFieldName="usrdata" Key="usrdata"> <Header Text="Data de Contacto" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="nome" Key="nome"> <Header Text="Nome" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="bino" Key="bino"> <Header Text="Nº CC/BI" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="nasc" Key="nasc"> <Header Text="Data de Nascimento" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="tlmvl" Key="tlmvl"> <Header Text="Telemóvel" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="codpost" Key="codpost"> <Header Text="Código Postal" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="local" Key="local"> <Header Text="Concelho" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="u_catprog" Key="u_catprog"> <Header Text="Categoria Profissional" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="U_STATUS" Key="U_STATUS"> <Header Text="Estado" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="U_AVALIACAO" Key="U_AVALIACAO"> <Header Text="Avaliação" /> </ig:BoundDataField> </Columns> <Behaviors> <ig:Filtering Enabled="true" EnableInheritance="true" FilterType="ExcelStyleFilter" /> <ig:Activation> </ig:Activation> <ig:Sorting> </ig:Sorting> </Behaviors> <Bands> <ig:Band Key="" DataMember="SqlDataSource2_DefaultView" DataKeyFields="cvestamp" AutoGenerateColumns="false"> <Columns> <ig:BoundDataField DataFieldName="morada" Key="morada"> <Header Text="Morada" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="tele" Key="tele"> <Header Text="Telefone" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="DISPONIBILIDADE" Key="DISPONIBILIDADE"> <Header Text="Disponibilidade" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="HAB_ACADEMICAS" Key="HAB_ACADEMICAS"> <Header Text="Habilitações" /> </ig:BoundDataField> <ig:BoundDataField DataFieldName="HAB_OUTRAS" Key="HAB_OUTRAS"> <Header Text="Outras Habilitações" /> </ig:BoundDataField> </Columns> </ig:Band> </Bands> </ig:WebHierarchicalDataGrid>
<ig:WebHierarchicalDataSource ID="WebHierarchicalDataSource1" runat="server"> <DataRelations> <ig:DataRelation ChildColumns="cvestamp" ChildDataViewID="SqlDataSource2_DefaultView" ParentColumns="cvestamp" ParentDataViewID="SqlDataSource1_Principal" /> </DataRelations> <DataViews> <ig:DataView ID="SqlDataSource1_Principal" DataSourceID="SqlDataSource1" /> <ig:DataView ID="SqlDataSource2_DefaultView" DataSourceID="SqlDataSource2" /> </DataViews> </ig:WebHierarchicalDataSource> <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:PHCConnectionString %>" SelectCommand="spDataSourceToGrid" SelectCommandType="StoredProcedure"></asp:SqlDataSource> <asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:PHCConnectionString %>" SelectCommand="spDataSourceToGrid" SelectCommandType="StoredProcedure"></asp:SqlDataSource></asp:Content>
and the code behind is:
protected void WebHierarchicalDataGrid1_Init(object sender, EventArgs e) { this.SqlDataSource1.DataBind(); this.SqlDataSource2.DataBind(); }
Im using Infragistics 2014.2
the error occurs when i try to expand a row.