NEW2JQ
NEW2JQ

Reputation: 11

jqGrid-subgrid is not showing up

'm creating 2nd level subgrid. followed the example (Sub Grid (2 nested levels)).
[jqgrid]http://www.trirand.net/demoaspnet.aspx when parent grid's row(+) symbol is clicked, It just shows one more empty row below It without column names, So I think, Its not even loading the subgrid on client. any ideas plz? >

**********aspx page:****************
< cc1:JQGrid ID="Jqgrid1" runat="server" OnDataRequesting="Jqgrid1_DataRequesting">
< SortSettings InitialSortColumn="" />
< Columns>
< cc1:JQGridColumn DataField="PrimaryId" PrimaryKey="True">
< /cc1:JQGridColumn>
< cc1:JQGridColumn DataField="ContractNumber"> < /cc1:JQGridColumn>
< cc1:JQGridColumn DataField="PONumber">
< /cc1:JQGridColumn>
< cc1:JQGridColumn DataField="POLineNumber">
< /cc1:JQGridColumn>
< cc1:JQGridColumn DataField="Description">
< /cc1:JQGridColumn>
< /Columns>
< ClientSideEvents SubGridRowExpanded="showSubGrid" />
< HierarchySettings HierarchyMode="Parent" />
< /cc1:JQGrid>
< /div>
< cc1:JQGrid ID="Jqgrid2" runat="server" OnDataRequesting="Jqgrid2_DataRequesting" >
< SortSettings InitialSortColumn="" />
< Columns>
< cc1:JQGridColumn DataField="BOMKEY" PrimaryKey="True" HeaderText="BKey">
< /cc1:JQGridColumn>
< cc1:JQGridColumn DataField="PARTNUMBER" HeaderText="Part#" >
< /cc1:JQGridColumn>
< cc1:JQGridColumn DataField="DESCRIPTION" HeaderText="Desc">
< /cc1:JQGridColumn>
< /Columns>
< HierarchySettings HierarchyMode="Child" />
< /cc1:JQGrid>
< script type="text/javascript">
function showSubGrid(subgrid_id, row_id) { showSubGrid_Jqgrid2(subgrid_id, row_id); }


******code behind******
protected void Jqgrid1_DataRequesting(object sender, > Trirand.Web.UI.WebControls.JQGridDataRequestEventArgs e)
{
if (!LoadPurchaseOrderLineDataSet())
{ return; }
Jqgrid1.DataSource = dtPurchaseOrderLine;
Jqgrid1.DataBind();
}
protected void Jqgrid2_DataRequesting(object sender, Trirand.Web.UI.WebControls.JQGridDataRequestEventArgs e)
{
LoadPurchaseOrderBOMDataSet(e.ParentRowKey);
Jqgrid2.DataSource = dsPurchaseOrderBOM;
Jqgrid2.DataBind();
}


Upvotes: 0

Views: 981

Answers (1)

NEW2JQ
NEW2JQ

Reputation: 11

I found solution - "Primary key should not contain any special characters".

Upvotes: 1

Related Questions