I need to set the property SortOrder
in the GridEx,
and this property is only get
.
What can I do?
the code:
private void M_Grid_ColumnHeaderClick(object sender, Janus.Windows.GridEX.ColumnActionEventArgs e)
{
if (e.Column.DataMember == "Filed1")
{
var list = m_Grid.DataSource;
if (e.Column.SortOrder == Janus.Windows.GridEX.SortOrder.Descending)
{
list = list.OrderBy(p => p.ParticipationDate).ToList();
e.Column.SortOrder = Janus.Windows.GridEX.SortIndicator.Ascending;// it's not good
}
else
{
list = list.OrderByDescending(p => p.ParticipationDate).ToList();
e.Column.SortOrder = Janus.Windows.GridEX.SortIndicator.Descending;// it's not good
}
m_Grid.DataSource = list;
}
}