private void TviewFilter_ItemClick(object sender, DevExpress.XtraGrid.Views.Tile.TileViewItemClickEventArgs e) { if (!IsMulti.Checked) { users.ForEach(t => t.IsChecked = false); GridCtlFilter.RefreshDataSource(); } ((FilterItem)TviewFilter.GetRow(e.Item.RowHandle)).IsChecked = !(bool)(TviewFilter.GetRowCellValue(e.Item.RowHandle, tIsChecked)); TviewFilter.RefreshRow(e.Item.RowHandle); }
private void IsMulti_CheckedChanged(object sender, EventArgs e) { if (!IsMulti.Checked) { users.ForEach(t => t.IsChecked = false); int[] s = TviewFilter.GetSelectedRows(); if (s.Length > 0) { users[s[0]].IsChecked = true; } GridCtlFilter.RefreshDataSource(); } }
private void loaddevice() { object sor = null; switch (_Model) { case "TASK": sor = Common.getDeviecSorByTask(_SelectedItem.Name); break; case "DEVICE": sor = Common.getDeviecSorByDevice(_SelectedItem.Type); break; } GridCtl.DataSource = sor; FilterItems[_selectedindex].Count = ((IEnumerable <TaskDevice>)sor).Where(t => !string.IsNullOrEmpty(t.ID)).Count(); GridCtlFilter.RefreshDataSource(); GridCtl.RefreshDataSource(); }