asp.netinfragisticswebdatagrid

WebDataGrid sorting with a generic list


I have a generic collection like this

Dim List(Of t) myData = data.GetData()
myWebDataGrid.DataSource = myData
myWebDataGrid.DataBind()

the config of the webdatagrid sort is this

<Behaviors>
   <ig:Sorting Enabled="true" SortingMode="Multi">
      <ColumnSettings>
          <ig:SortingColumnSetting ColumnKey="Key1" Sortable="true" />
      </ColumnSettings>
   </ig:Sorting>
</Behaviors>

but when I set the sortable property on this control and run the page... I just try to sort and all the data disappears.


Solution

  • I realized that after the postback I have to set the data again.