I'm using Infragistics version: 7.1.20071.1045
I'm trying to use the UltraWebGrid to display data and want to sort the contents but whichever column I put the sort on all the values for that column become empty. If I don't sort any columns all the data displays, if I don't sort any columns and then click on the column header to sort it, it sorts properly. Here is the relevant code:
private void Page_Load(object sender, System.EventArgs e) { BindEvents(); if (IsPostBack == false) { uwgEmailEvent.DataBind(); } }
private void BindEvents() { uwgEmailEvent.DataBinding += new EventHandler(uwgEmailEvent_DataBinding); uwgEmailEvent.InitializeLayout += new Infragistics.WebUI.UltraWebGrid.InitializeLayoutEventHandler(uwgEmailEvent_InitializeLayout); }
private void uwgEmailEvent_DataBinding(object sender, EventArgs e) { uwgEmailEvent.DataSource = EmailEventBfo.GetEmailEvents(PortalGuid); }
private void uwgEmailEvent_InitializeLayout(object sender, Infragistics.WebUI.UltraWebGrid.LayoutEventArgs e) { uwgEmailEvent.Bands[0].Columns.FromKey("EventType").SortIndicator = Infragistics.WebUI.UltraWebGrid.SortIndicator.Ascending; uwgEmailEvent.Bands[0].SortedColumns.Insert(0, uwgEmailEvent.Columns.FromKey("EventType"), true); }