# Buscar dato en Perder foco

**URL:** <https://foros.velneo.com/t/buscar-dato-en-perder-foco/9213>\
**Category:** Velneo\
**Created:** [1 Diciembre, 2016 16:26 UTC](https://foros.velneo.com/t/buscar-dato-en-perder-foco/9213 "2016-12-01T16:26:57Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![leonardo-daniel-vela](https://avatars.discourse-cdn.com/v4/letter/l/f9ae1b/32.png) [@leonardo-daniel-vela](https://foros.velneo.com/u/leonardo-daniel-vela)\
**Post date:** [1 Diciembre, 2016 16:26 UTC](https://foros.velneo.com/t/buscar-dato-en-perder-foco/9213/1 "2016-12-01T16:26:57Z")

</div>

Hola a todos, una pregunta… como hago para que se limpie en el formulario los datos del viaje, si se captura un viaje que no le pertenece al conductor, muestro el mensaje, pero como hago para limpiar o ponerle un “0” y que limpie los datos

**Manejador de evento: VALIDA\_CHOFER\_VIAJE**

```auto
Set ( CHOFER, #CHOFER )
Set ( VIAJE_IDA, #VIAJE_IDA )
Set ( NO_ES_CHOFER, 1 )
Cargar lista ( VIAJES@vAztecaDat, ID, VIAJE_IDA, , , )
      If ( sysListSize ! 0 )
            Seleccionar ficha por posición ( 1 )
            Leer ficha seleccionada
                  If ( (CHOFER = #CHOFER1) & (VIAJE_IDA = #ID) & (#IDA_VUELTA = "I") )
                        Set ( NO_ES_CHOFER, 0 )
                        Set ( VIAJE_VUELTA, #ID )
                  Else if ( (CHOFER = #CHOFER2) & (VIAJE_IDA = #ID) & (#IDA_VUELTA = "I") )
                        Set ( NO_ES_CHOFER, 0 )
                  Else
                        Set ( NO_ES_CHOFER, 1 )
                        Libre
                  Libre
      Libre
Libre
If ( NO_ES_CHOFER )
      Mensaje ( "Load # " + VIAJE_IDA + " does not correspond to that driver. Please enter Northbond
Load #", Información, , "Alert" )
      Libre
Libre
Set dato de retorno ( NO_ES_CHOFER )

```

---

<div class="post-metadata">

**Author:** ![ereitmann](https://avatars.discourse-cdn.com/v4/letter/e/8491ac/32.png) [@ereitmann](https://foros.velneo.com/u/ereitmann)\
**Post date:** [4 Diciembre, 2016 16:24 UTC](https://foros.velneo.com/t/buscar-dato-en-perder-foco/9213/2 "2016-12-04T16:24:38Z")

</div>

yo crearía un formulario sin origen con variables locales para las busquedas, creas un manejador de evento que dispare otro formulario al que le pasas esas variables locales o en funcion previa de una búsqueda dispara un formulario mostrando el viaje que si corresponda y si no el mensaje y al retorno al fina de esa manejador de evento pon en 0 o vacías todas las variables
