public override void UpdateList() { switch (_current_action) { case molAction.Add: case molAction.Copy: if (_entity == null) { return; } List.AddItem(_entity.GetInfo(false)); if (FilterType == IFilterType.Filter) { OutputInvoiceList listA = OutputInvoiceList.GetList((SortedBindingList <OutputInvoiceInfo>)_filter_results); listA.AddItem(_entity.GetInfo(false)); _filter_results = listA.GetSortedList(); } break; case molAction.Edit: case molAction.ChangeStateContabilizado: case molAction.ChangeStateEmitido: case molAction.Unlock: case molAction.PrintDetail: case molAction.ExportPDF: case molAction.EmailPDF: if (_entity == null) { return; } ActiveItem.CopyFrom(_entity); break; case molAction.Delete: if (ActiveItem == null) { return; } List.RemoveItem(ActiveOID); if (FilterType == IFilterType.Filter) { OutputInvoiceList listD = OutputInvoiceList.GetList((SortedBindingList <OutputInvoiceInfo>)_filter_results); listD.RemoveItem(ActiveOID); _filter_results = listD.GetSortedList(); } break; } RefreshSources(); if (_entity != null) { Select(_entity.Oid); } _entity = null; }