PDA

View Full Version : [CLOSED] Nested childgrid autoselection issue



amitpareek
Jun 02, 2016, 4:56 PM
Hi Guys

I have grid and a nested childgrid with CheckboxSelectionModel in both parent and childgrid , when i select parent grid row all the child grid row gets selected as well . This selection is not shown in selectionmodel() of the childgrid . So when i try to clear i cant clear them

What i need is prevent selection of childgrid items on selecting parent grid row

My Grid Code is below


<ext:GridPanel runat="server" Split="true" Title="Results" Region="North" ID="gridResults" ItemID="gridResults"
Height="320" MultiSelect="true"
Header="false" CollapseMode="Mini" Border="false" AnimCollapse="true" Collapsed="true" HideHeaders="true">

<Store>
<ext:Store ID="storeResults" ItemID="storeResults" runat="server" GroupField="genericName" GroupDir="ASC">
<Sorters>
<ext:DataSorter Property="drugName" Direction="ASC"></ext:DataSorter>
</Sorters>
<Reader>
<ext:JsonReader IDProperty="fileId"></ext:JsonReader>
</Reader>
<Model>
<ext:Model ID="ModelResult" runat="server">
<Fields>
<ext:ModelField Name="productId" Mapping="fileId"></ext:ModelField>
<ext:ModelField Name="fileId"></ext:ModelField>
<ext:ModelField Name="drugName">
<Convert Handler="return value==''?'Unknown Drug Name':value;"></Convert>
</ext:ModelField>
<ext:ModelField Name="manufacturername">
<Convert Handler="return value==''?'Unknown Manufacturer Name':value.toUpperTitleCase();"></Convert>
</ext:ModelField>

<ext:ModelField Name="Manufacturer Name" Mapping="manufacturername">
<Convert Handler="return value==''?'Unknown Manufacturer Name':value.toUpperTitleCase();"></Convert>
</ext:ModelField>

<ext:ModelField Name="drugClass">
<Convert Handler="return value==''?'Unknown Drug Class':value;"></Convert>
</ext:ModelField>

<ext:ModelField Name="Short Drug Class" Mapping="drugClass">
<Convert Handler="return value==''?'Unknown Drug Class':value;"></Convert>
</ext:ModelField>

<ext:ModelField Name="Drug Class" Mapping="drugClass">
<Convert Handler="return value==''?'Unknown Drug Class':value;"></Convert>
</ext:ModelField>

<ext:ModelField Name="ShortDrugName">
<Convert Handler="if(record.data.drugName==null)record.data.drugName ='';return record.data.drugName.substring(0,70);"></Convert>
</ext:ModelField>
<ext:ModelField Name="version">
</ext:ModelField>
<ext:ModelField Name="newVersion" Mapping="version">
<Convert Handler="return 'v' + record.data.version;"></Convert>
</ext:ModelField>
<ext:ModelField Name="date" Type="Date"></ext:ModelField>
<ext:ModelField Name="nonProprietaryname">
<Convert Handler="return value==''?'Unknown Generic Name':value;"></Convert>
</ext:ModelField>
<ext:ModelField Name="NPN" Mapping="nonProprietaryname">
<Convert Handler="return value==''?'Unknown Generic Name':value.toUpperTitleCase();"></Convert>
</ext:ModelField>

<ext:ModelField Name="Generic Name" Mapping="nonProprietaryname">
<Convert Handler="return record.data.NPN.toUpperTitleCase();"></Convert>
</ext:ModelField>
<ext:ModelField Name="html"></ext:ModelField>
<ext:ModelField Name="setID"></ext:ModelField>
<ext:ModelField Name="followSearch"></ext:ModelField>
<ext:ModelField Name="dosage"></ext:ModelField>
<ext:ModelField Name="hasVersions"></ext:ModelField>
<ext:ModelField Name="applNo" Mapping="applNo"></ext:ModelField>
<ext:ModelField Name="hasDoc"></ext:ModelField>
<ext:ModelField Name="proprietaryname">
<Convert Handler="return value==''?'Unknown Brand Name':value;"></Convert>
</ext:ModelField>
<ext:ModelField Name="Brand Name" Mapping="proprietaryname">
<Convert Handler="return value==''?'Unknown Brand Name':value;"></Convert>
</ext:ModelField>
<ext:ModelField Name="Country" Mapping="country"></ext:ModelField>
<ext:ModelField Name="type" Mapping="type"></ext:ModelField>
<ext:ModelField Name="status">
</ext:ModelField>
<ext:ModelField Name="approveStatus"></ext:ModelField>
<ext:ModelField Name="url"></ext:ModelField>
</Fields>
</ext:Model>
</Model>
<Listeners>
<GroupChange Handler="if(App.gridMask){App.gridMask.hide();}"></GroupChange>
<Refresh Handler="if(App.gridMask){App.gridMask.hide();}"></Refresh>--%>

<Load Handler="App.onStoreLoad();" Delay="100" Buffer="500"></Load>
<GroupChange Handler="App.onStoreGroupChange();"></GroupChange>
<Refresh Handler="App.onStoreRefresh();"></Refresh>
</Listeners>
</ext:Store>
</Store>

<ColumnModel ID="ColumnModel31" runat="server">

<Columns>

<ext:Column ID="col123" runat="server" Text="Label Title" Flex="5" DataIndex="setID">
<Renderer Handler="return Controls.Search.getSearchIcon(record)"></Renderer>
</ext:Column>
<ext:Column runat="server" Text="Version" DataIndex="newVersion" Flex="1"></ext:Column>
<ext:Column runat="server" Text="Dosage" DataIndex="dosage" Flex="2"></ext:Column>
<ext:Column runat="server" Text="Revision Date" DataIndex="date" Flex="2">
<Renderer Format="Date" FormatArgs="'j F, Y'" />
</ext:Column>



</Columns>

</ColumnModel>

<View>
<ext:GridView ItemID="GridView1" runat="server" PreserveScrollOnRefresh="false" MultiSelect="true">
<GetRowClass Fn="App.getRowClass" />
</ext:GridView>

</View>
<Features>
<%--="#{Grouping1}[#{Grouping1}.expanded ? 'collapseAll' : 'expandAll'](); #{Grouping1}.expanded = !#{Grouping1}.expanded;" --%>

<ext:Grouping ID="gridResultsGroup" Namespace="App" ItemID="gridResultsGroup" GroupHeaderTplString="{columnName} : {name} ({[values.rows.length]} Item{[values.rows.length > 1 ? 's' : '']})" StartCollapsed="true" runat="server">
</ext:Grouping>

</Features>
<SelectionModel>
<ext:CheckboxSelectionModel ID="chkSelectionModelGridResults" XCheckOnly="true" PruneRemoved="false" ShowHeaderCheckbox="false" CheckOnly="true"
runat="server">
<Listeners>
<Select Fn="App.onDrugSelect"></Select>
<Deselect Fn="App.onDrugDeselect"></Deselect>
</Listeners>
</ext:CheckboxSelectionModel>

</SelectionModel>
<Plugins>

<ext:RowExpander ID="gridResultsExpander" Visible="true" runat="server" ExpandOnDblClick="false" IDMode="Explicit">

<Component>

<ext:GridPanel ID="gridChild1" runat="server" PageX="55" ForceFit="true" Width="930" EnableColumnHide="false">
<Store>
<ext:Store ID="Store167" runat="server" AutoLoad="false">
<Reader>
<%--<ext:JsonReader IDProperty="fileId"></ext:JsonReader>--%>
<ext:JsonReader></ext:JsonReader>
</Reader>
<Model>
<ext:Model ID="Model257" runat="server">
<Fields>
<ext:ModelField Name="fileId"></ext:ModelField>
<ext:ModelField Name="version"></ext:ModelField>
<ext:ModelField Name="effectiveTime" Type="Date"></ext:ModelField>
<ext:ModelField Name="html"></ext:ModelField>
<ext:ModelField Name="setID"></ext:ModelField>
<ext:ModelField Name="drugName" Mapping="DrugName"></ext:ModelField>
<ext:ModelField Name="ShortDrugName">
<Convert Handler="if(record.data.drugName==null)record.data.drugName ='';return record.data.drugName.substring(0,70);"></Convert>
</ext:ModelField>
<ext:ModelField Name="Country"></ext:ModelField>

</Fields>
</ext:Model>
</Model>

</ext:Store>
</Store>

<ColumnModel ID="ColumnModel2" runat="server">
<Columns>
<ext:Column runat="server" Text="Label Title" DataIndex="ShortDrugName" ID="Column5" Width="550" MaxWidth="550">
</ext:Column>
<ext:Column ID="Column6" runat="server" Text="Version" DataIndex="version" Width="50">
</ext:Column>

<ext:Column ID="Column7" runat="server" Text="Revision Date" DataIndex="effectiveTime" Width="150">
<Renderer Format="Date" FormatArgs="'j F, Y'" />
</ext:Column>
<ext:CommandColumn ID="CommandColumn2" runat="server" Width="180">
<Commands>
<ext:GridCommand Text="View" Icon="ApplicationViewDetail" CommandName="viewHtml" MinWidth="50"></ext:GridCommand>
</Commands>
<Listeners>
<Command Fn="App.SearchResultsCommands"></Command>
</Listeners>
</ext:CommandColumn>
</Columns>
</ColumnModel>
<SelectionModel>
<ext:CheckboxSelectionModel ID="chkgridchildselectionmodel" XCheckOnly="true" PruneRemoved="false" ShowHeaderCheckbox="false" CheckOnly="true"
runat="server">
<Listeners>
<Select Fn="App.onDrugSelect"></Select>
<Deselect Fn="App.onDrugDeselect"></Deselect>
</Listeners>
</ext:CheckboxSelectionModel>

</SelectionModel>
<View>
<ext:GridView ID="GridView2" runat="server" PreserveScrollOnRefresh="true">
</ext:GridView>
</View>

</ext:GridPanel>

</Component>

<Listeners>
<BeforeExpand Handler="#{gridChild1}.store.removeAll();"></BeforeExpand>
</Listeners>
<DirectEvents>
<Expand
Url="~/Search/BeforeGridRowExpand"
Success="body.rendered=true;App.onSuccessGridRowExpand(#{gr idChild1}, result);" Timeout="90000">
<EventMask ShowMask="true" Target="CustomTarget" CustomTarget="={#{gridResults}.body}" />
<ExtraParams>
<ext:Parameter Name="setId" Value="record.data.setID" Mode="Raw" />
<ext:Parameter Name="version" Value="record.data.version" Mode="Raw"></ext:Parameter>
<ext:Parameter Name="country" Value="record.data.NPN == 'Uploaded Documents' ? ('cds' + record.data.Country) : record.data.Country" Mode="Raw"></ext:Parameter>
<ext:Parameter Name="formatValue" Value="record.data.productId" Mode="Raw"></ext:Parameter>
</ExtraParams>
</Expand>
</DirectEvents>

<Renderer Handler="return record.data.hasVersions >= 2;"></Renderer>
</ext:RowExpander>
</Plugins>
<Listeners>
<AfterRender Handler="App.setGridMask(); App.setOnGridCollapseEvent();"></AfterRender>
<ItemContextMenu Fn="App.getContextMenu" />
</Listeners>

</ext:GridPanel>




Thanks
Amit

geoffrey.mcgill
Jun 02, 2016, 5:57 PM
Hi,

I tried running your code sample, but Exceptions were thrown.

Can you provide a simplified code sample demonstrating how to reproduce the problem? Something we can copy + paste into a local test project and run without having to make major modifications?

The Forum Guidelines (http://forums.ext.net/showthread.php?3440) provide lots of helpful tips on posting in the forums.

amitpareek
Jun 03, 2016, 12:26 PM
Here is my issue reproduction code

Select any parent grid checkbox ,In child grid all checkbox get selected and they are not available in selectionmodel
I want to prevent selection of childgrid checkboxes please. or any work around .



<%@ page language="C#" autoeventwireup="true" codefile="Default.aspx.cs" inherits="_Default" %>

<%@ register assembly="Ext.Net" namespace="Ext.Net" tagprefix="ext" %>


<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>


<script type="text/javascript">
var template = '<span style="color:{0};">{1}</span>';

var change = function (value) {
return String.format(template, (value > 0) ? "green" : "red", value);
};

var pctChange = function (value) {
return String.format(template, (value > 0) ? "green" : "red", value + "%");
};
</script>


</head>
<body>
<form id="form1" runat="server">
<div>

<ext:resourcemanager id="ResourceManager1" runat="server" cleanresourceurl="true" directmethodnamespace="DM" namespace="app">
</ext:resourcemanager>

<ext:viewport runat="server">
<Items>


<ext:GridPanel
ID="GridPanel1"
runat="server"
Title="Array Grid"
Width="700" AutoHeight="true">
<Store>
<ext:Store ID="Store1" runat="server" OnReadData="MyData_Refresh" PageSize="10">
<Reader>
<ext:ArrayReader>
<Fields>
<ext:RecordField Name="company" />
<ext:RecordField Name="price" Type="Float" />
<ext:RecordField Name="change" Type="Float" />
<ext:RecordField Name="pctChange" Type="Float" />
<ext:RecordField Name="lastChange" Type="Date" DateFormat="M/d hh:mmtt" />
</Fields>
</ext:ArrayReader>
</Reader>

</ext:Store>
</Store>


<columnmodel runat="server">
<Columns>
<ext:Column ColumnID="Company" Header="Company" DataIndex="company" />
<ext:Column Header="Price" DataIndex="price">
<Renderer Format="UsMoney" />
</ext:Column>
<ext:Column ColumnID="Change" Header="Change" DataIndex="change">
<Renderer Fn="change" />
</ext:Column>
<ext:Column Header="Change" DataIndex="pctChange">
<Renderer Fn="pctChange" />
</ext:Column>
<ext:DateColumn Header="Last Updated" DataIndex="lastChange" />
</Columns>
</columnmodel>

<SelectionModel>
<ext:CheckboxSelectionModel runat="server"></ext:CheckboxSelectionModel>
</SelectionModel>

<View>
<ext:GridView runat="server" StripeRows="true" />
</View>

<plugins>

<ext:RowExpander ID="gridResultsExpander" Visible="true" runat="server" ExpandOnDblClick="false">

<Component>

<ext:GridPanel
ID="gridChild1"
runat="server"

Width="500" AutoHeight="true" EnableColumnHide="false">
<Store>
<ext:Store ID="Store2" runat="server" OnReadData="MyChildData_Refresh" PageSize="10">
<Reader>
<ext:ArrayReader>
<Fields>
<ext:RecordField Name="company" />
<ext:RecordField Name="price" Type="Float" />
</Fields>
</ext:ArrayReader>
</Reader>


</ext:Store>
</Store>

<columnmodel runat="server">
<Columns>
<ext:Column ColumnID="Company" Header="Company" DataIndex="company" />
<ext:Column Header="Price" DataIndex="price">
<Renderer Format="UsMoney" />
</ext:Column>
</Columns>
</columnmodel>

<SelectionModel>
<ext:CheckboxSelectionModel runat="server" XCheckOnly="true" PruneRemoved="false" ShowHeaderCheckbox="false" CheckOnly="true"
></ext:CheckboxSelectionModel>
</SelectionModel>


</ext:GridPanel>

</Component>
</ext:RowExpander>

</plugins>
</ext:GridPanel>

</Items>

</ext:viewport>


</div>
</form>
</body>
</html>





C# code below



using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Ext.Net;
public partial class _Default : System.Web.UI.Page{


protected void Page_Load(object sender, EventArgs e)
{
if (!X.IsAjaxRequest)
{

this.Store1.DataSource = this.Data;
this.Store1.DataBind();



this.Store2.DataSource = this.Data2;
this.Store2.DataBind();
}
}

protected void MyData_Refresh(object sender, StoreRefreshDataEventArgs e)
{
this.BindData();
}

protected void MyChildData_Refresh(object sender, StoreRefreshDataEventArgs e)
{
this.BindChildData();
}

private void BindData()
{
Store store = this.GridPanel1.GetStore();

store.DataSource = this.Data;
store.DataBind();
}

private void BindChildData()
{
Store store = this.gridChild1.GetStore();

store.DataSource = this.Data2;
store.DataBind();
}


private object[] Data
{
get
{
DateTime now = DateTime.Now;

return new object[]
{
new object[] { "3m Co", 71.72, 0.02, 0.03, now },
new object[] { "Alcoa Inc", 29.01, 0.42, 1.47, now },
new object[] { "Altria Group Inc", 83.81, 0.28, 0.34, now },
new object[] { "American Express Company", 52.55, 0.01, 0.02, now },
new object[] { "American International Group, Inc.", 64.13, 0.31, 0.49, now },
new object[] { "AT&T Inc.", 31.61, -0.48, -1.54, now },
new object[] { "Boeing Co.", 75.43, 0.53, 0.71, now },
new object[] { "Caterpillar Inc.", 67.27, 0.92, 1.39, now },
new object[] { "Citigroup, Inc.", 49.37, 0.02, 0.04, now },
new object[] { "E.I. du Pont de Nemours and Company", 40.48, 0.51, 1.28, now },
new object[] { "Exxon Mobil Corp", 68.1, -0.43, -0.64, now },
new object[] { "General Electric Company", 34.14, -0.08, -0.23, now },
new object[] { "General Motors Corporation", 30.27, 1.09, 3.74, now },
new object[] { "Hewlett-Packard Co.", 36.53, -0.03, -0.08, now }
};
}
}


private object[] Data2
{
get
{
DateTime now = DateTime.Now;

return new object[]
{
new object[] { "Wipro", 71.72,now },
new object[] { "Infosys", 29.01, 1.47, now },
new object[] { "Wal-Mart Stores, Inc.", 45.45, now }
};
}
}



}

amitpareek
Jun 06, 2016, 4:56 PM
Can any one reply on this please .

fabricio.murta
Jun 07, 2016, 2:34 AM
Hello @amitpareek!

Your aspx code gives syntax errors. Are you using latest 2.x version? I'm afraid we should have you provide test cases that runs on the latest Ext.NET v2 before we can be able to help you.

amitpareek
Jun 07, 2016, 8:53 AM
Hi fabricio.murta ,

The aspx code and c# code i posted 2nd time is picked from examples2.ext.net , I understand the first post is throwing error , we are using Ext 2.0 . Please try again with the code posted starting #3 , http://forums.ext.net/showthread.php?61175-Nested-childgrid-autoselection-issue&p=278931&viewfull=1#post278931


(http://forums.ext.net/showthread.php?61175-Nested-childgrid-autoselection-issue&p=278931&viewfull=1#post278931)

fabricio.murta
Jun 07, 2016, 4:22 PM
Hello @amitpareek!

Sorry, Ext.NET 2.0 is at least 12 reviews behind the latest public Ext.NET (which is 2.5.3.1), and some more older than the latest SVN. Unfortunately, we can't keep reviewing errors on older releases specially when we might already have fixed them. We would require you to post a sample that can be run at least on 2.5.3 so we can even determine if this error has been fixed, is still actual, or if there's a better approach to take on the latest Ext.NET 2.x.

We hope you understand! Ideally you should be using SVN version of Ext.NET.

asifsolkar
Jun 07, 2016, 5:49 PM
Hi @fabricio

we are in process of upgrading to 4.1 In older version we are on Ext 2.2, Can you please try to run this code in version 2.5 and let me know , I am sure you will see this issue there too

Thanks

fabricio.murta
Jun 07, 2016, 7:07 PM
Hello @asifsolkar.

As stated here (http://forums.ext.net/showthread.php?61175-Nested-childgrid-autoselection-issue&p=278965&viewfull=1#post278965), the code does not run on latest Ext.NET 2.x series. Either public 2.5 or SVN. This will also most likely not work on 3.x or 4.x.

Unfortunately between some 2.x versions of Ext.NET there were breaking changes. Not that we could control that, heavy changes took place on the underlying framework (ExtJS from Sencha) at the time.

asifsolkar
Jun 10, 2016, 10:15 AM
Hi @Fabrico

Updated dll to using nugets Install-Package Ext.NET -Version 2.5.3.1

uploaded project files here , please download you can add to project and run

asifsolkar
Jun 14, 2016, 9:53 AM
Hi @fabrico

I added github link thinking it will be easier for you to address the issue
please check code below ,

Default.aspx


<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>

<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>


<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>


<script type="text/javascript">
var template = '<span style="color:{0};">{1}</span>';

var change = function (value) {
return String.format(template, (value > 0) ? "green" : "red", value);
};

var pctChange = function (value) {
return String.format(template, (value > 0) ? "green" : "red", value + "%");
};
</script>


</head>
<body>
<form id="form1" runat="server">
<div>

<ext:ResourceManager ID="ResourceManager1" runat="server" CleanResourceUrl="true" DirectMethodNamespace="DM" Namespace="app">
</ext:ResourceManager>

<ext:Viewport runat="server">
<Items>

<ext:GridPanel
ID="GridPanel1"
runat="server"
Title="Array Grid"
Width="700" AutoHeight="true">
<Store>
<ext:Store ID="Store1" runat="server" PageSize="10">
<Model>
<ext:Model runat="server">
<Fields>
<ext:ModelField Name="company" />
<ext:ModelField Name="price" Type="Float" />
<ext:ModelField Name="change" Type="Float" />
<ext:ModelField Name="pctChange" Type="Float" />
<ext:ModelField Name="lastChange" Type="Date" DateFormat="M/d hh:mmtt" />
</Fields>

</ext:Model>

</Model>

</ext:Store>
</Store>


<ColumnModel runat="server">
<Columns>


<ext:Column ID="Company" Header="Company" DataIndex="company" runat="server" />

<ext:Column Header="Price" DataIndex="price" runat="server">
<Renderer Format="UsMoney" />
</ext:Column>
<ext:Column ColumnID="Change" Header="Change" DataIndex="change" runat="server">
<Renderer Fn="change" />
</ext:Column>
<ext:Column Header="Change" DataIndex="pctChange" runat="server">
<Renderer Fn="pctChange" />
</ext:Column>
<ext:DateColumn Header="Last Updated" DataIndex="lastChange" runat="server" />
</Columns>
</ColumnModel>

<SelectionModel>
<ext:CheckboxSelectionModel runat="server"></ext:CheckboxSelectionModel>
</SelectionModel>

<View>
<ext:GridView runat="server" StripeRows="true" />
</View>

<Plugins>

<ext:RowExpander ID="gridResultsExpander" Visible="true" runat="server" ExpandOnDblClick="false">

<Component>

<ext:GridPanel
ID="gridChild1"
runat="server"
Width="500" AutoHeight="true" EnableColumnHide="false">
<Store>
<ext:Store ID="Store2" runat="server" PageSize="10">
<Model>
<ext:Model runat="server">
<Fields>
<ext:ModelField Name="company" />
<ext:ModelField Name="price" Type="Float" />
<ext:ModelField Name="change" Type="Float" />

</Fields>
</ext:Model>

</Model>

</ext:Store>
</Store>
<ColumnModel runat="server">
<Columns>
<ext:Column ColumnID="Company" Header="Company" DataIndex="company" runat="server" />
<ext:Column Header="Price" DataIndex="price" runat="server">
<Renderer Format="UsMoney" />
</ext:Column>
</Columns>
</ColumnModel>

<SelectionModel>
<ext:CheckboxSelectionModel runat="server" XCheckOnly="true" PruneRemoved="false" ShowHeaderCheckbox="false" CheckOnly="true">
</ext:CheckboxSelectionModel>
</SelectionModel>


</ext:GridPanel>

</Component>
</ext:RowExpander>

</Plugins>
</ext:GridPanel>

</Items>

</ext:Viewport>


</div>
</form>
</body>
</html>




c# code below
default.aspx.cs


using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Ext.Net;
public partial class _Default : System.Web.UI.Page{


protected void Page_Load(object sender, EventArgs e)
{
if (!X.IsAjaxRequest)
{

this.Store1.DataSource = this.Data;
this.Store1.DataBind();



this.Store2.DataSource = this.Data2;
this.Store2.DataBind();
}
}

protected void MyData_Refresh(object sender, StoreDirectEvents e)
{
this.BindData();
}

protected void MyChildData_Refresh(object sender, StoreDirectEvents e)
{
this.BindChildData();
}

private void BindData()
{
Store store = this.GridPanel1.GetStore();

store.DataSource = this.Data;
store.DataBind();
}

private void BindChildData()
{
Store store = this.gridChild1.GetStore();

store.DataSource = this.Data2;
store.DataBind();
}


private object[] Data
{
get
{
DateTime now = DateTime.Now;

return new object[]
{
new object[] { "3m Co", 71.72, 0.02, 0.03, now },
new object[] { "Alcoa Inc", 29.01, 0.42, 1.47, now },
new object[] { "Altria Group Inc", 83.81, 0.28, 0.34, now },
new object[] { "American Express Company", 52.55, 0.01, 0.02, now },
new object[] { "American International Group, Inc.", 64.13, 0.31, 0.49, now },
new object[] { "AT&T Inc.", 31.61, -0.48, -1.54, now },
new object[] { "Boeing Co.", 75.43, 0.53, 0.71, now },
new object[] { "Caterpillar Inc.", 67.27, 0.92, 1.39, now },
new object[] { "Citigroup, Inc.", 49.37, 0.02, 0.04, now },
new object[] { "E.I. du Pont de Nemours and Company", 40.48, 0.51, 1.28, now },
new object[] { "Exxon Mobil Corp", 68.1, -0.43, -0.64, now },
new object[] { "General Electric Company", 34.14, -0.08, -0.23, now },
new object[] { "General Motors Corporation", 30.27, 1.09, 3.74, now },
new object[] { "Hewlett-Packard Co.", 36.53, -0.03, -0.08, now }
};
}
}


private object[] Data2
{
get
{
DateTime now = DateTime.Now;

return new object[]
{
new object[] { "Wipro", 71.72,now },
new object[] { "Infosys", 29.01, 1.47, now },
new object[] { "Wal-Mart Stores, Inc.", 45.45, now }
};
}
}



}

fabricio.murta
Jun 15, 2016, 1:44 AM
Hello @asifsolkar!

Sorry, we understand you wanted to make it simple, but for several reasons we decided not to support sharing projects. To name one, a project you shared today may not be available tomorrow for the ones having the same issue. And having the simplified code on the thread really makes it both easier to be reproduced and easier to be replied -- as the code source is smaller. Also easier to have the solution understood.

Additionally, per our guidelines on forums it has been mentioned that a project file should be provided only when requested, but turned out this did turn out that it was easier and always possible to provide the code sample in [code] tags in the end... So we recently decided on dropping full project sharing off completely. Another implication would be the chance keys were being publicized and code not meant to were being also duplicated (like proprietary algorithms, for example).

Well, explanations given, we'll be analyzing your sample code and will return soon with feedback!

Hope you understand!

fabricio.murta
Jun 15, 2016, 2:35 AM
Hello again, and for the feedback.

Well, this will not be a long explanation but there are limitations on the Row Expander plugin that you are just exploring them. Unfortunately they are known not to work and should be avoided.

Please refer to this example, it mentions this checkbox selection model and other limitations on nested grid panels: Grid Panel > Row Expander > Multi Level (http://examples2.ext.net/#/GridPanel/RowExpander/MultiLevel_GridPanel/).

Sorry the news are not really great, but I hope this helps!

asifsolkar
Jun 15, 2016, 5:48 AM
Hi @Fabrico

Will this work with ext 4.1 ?

fabricio.murta
Jun 16, 2016, 4:52 AM
Hello @asifsolkar!

Unfortunately no, these issues are still in place down the road to Ext.NET 4.1. As you can see in the corresponding RowExpander (http://examples4.ext.net/#/GridPanel/RowExpander/MultiLevel_GridPanel/) example.

amitpareek
Jan 24, 2017, 2:24 PM
Do we have any update here ? Downloaded latest from SVN Yesterday 23-Jan-2017, still doesn't seem to work.

fabricio.murta
Jan 24, 2017, 4:27 PM
Hello @amitpareek!

This still is a limitation with the row expander model, unfortunately.

fabricio.murta
Jan 24, 2017, 8:18 PM
Hello again @amitpareek!

Although there's this limitation it does not mean there's no solution for this on Ext.NET 4. If you want us to try and show you alternatives on enabling this behavior with nested grid panels, please open a thread on 4.x forums. I'm sure we can get up to something.

amitpareek
Jan 25, 2017, 1:50 PM
Issue created on 4.x premium

http://forums.ext.net/showthread.php?61719-Selection-issue-on-Childgrid-in-rowExpander