private void UiListaVistaOperadores_SelectionChanged(object sender, DevExpress.Data.SelectionChangedEventArgs e)
        {
            if (e.ControllerRow >= 0)
            {
                var documento = (Usuario)UiListaVistaOperadores.GetRow(e.ControllerRow);
                documento.IS_SELECTED = (e.Action == CollectionChangeAction.Add);
            }
            else
            {
                if (UsuarioSeleccionoListaOperadoresCompleta)
                {
                    for (var i = 0; i < UiListaVistaOperadores.RowCount; i++)
                    {
                        var documento = (Usuario)UiListaVistaOperadores.GetRow(i);
                        if (documento == null)
                        {
                            continue;
                        }
                        documento.IS_SELECTED = (UiListaVistaOperadores.SelectedRowsCount != 0);
                    }
                    UsuarioSeleccionoListaOperadoresCompleta = false;
                }
            }

            var edit = ActiveControl as DevExpress.XtraEditors.SearchLookUpEdit;

            if (edit == null)
            {
                return;
            }
            edit.Text = ObtenerTextoAMostrarListaOperadores();
        }
 private void UiListaVistaOperadores_BeforeLeaveRow(object sender, DevExpress.XtraGrid.Views.Base.RowAllowEventArgs e)
 {
     for (var i = 0; i < UiListaVistaOperadores.RowCount; i++)
     {
         var documento = (Usuario)UiListaVistaOperadores.GetRow(i);
         if (documento == null)
         {
             continue;
         }
         if (documento.IS_SELECTED)
         {
             UiListaVistaOperadores.SelectRow(i);
         }
     }
 }