DataList control in DataListItem

  • Thread starter Thread starter Mirek Endys
  • Start date Start date
M

Mirek Endys

I need to know, how to bind data into DataList, that is placed in another
DataList in SelectedItemTemplate.
I tried to FindControl on ItemCreated event, on PageLoad event, but I cannot
get this control???

How to do this???

Thanks

Mirek
 
I have found that.
I have Bound parent dataList in code by:

dlDTDefinitions.DataSource = transfers;
dlDTDefinitions.DataBind();

transfers is a List<iDB2SQLTransferItem> and the item (iDB2SQLTransferItem)
contain DataMappings that is List<DataMappingItem>.

in aspx i have to bind DataSource of the child DataList:

<asp:DataList ID="dlDataMapping" runat="server" DataSource='<%#
DataBinder.Eval(Container.DataItem, "DataMappings") %>'>

Thats all
 
Back
Top