Page 1 of 1

GET MULTILINE

PostPosted: Tue Dec 12, 2017 10:48 pm
by acuellar
Estimados

Tengo un GET MULTILINE y quiero que grabe sólo cuando pierde el Focus el GET
Algo Asi:

Code: Select all  Expand view

@80,180 GET oGet VAR cTEXTO OF oWnd PIXEL SIZE 200,137 MULTILINE
    oGet:bChange = { || If( oGet:lfocus(), Graba(), ) }
 


oGet:lostfocus() --> Da error

Gracias por la ayuda

Re: GET MULTILINE

PostPosted: Tue Dec 12, 2017 11:38 pm
by FranciscoA
Adhemar, ya probaste asi?
oGet:bLostFocus := {|| msginfo("Tu funcion") }

Saludos.

Re: GET MULTILINE

PostPosted: Wed Dec 13, 2017 1:02 pm
by acuellar
Gracias Francisco.

De la forma que me indicas, siempre pasará por la función cuando ha perdido el focus.
Lo que necesito es cuando se realizado un cambio recién vaya a la función.

Re: GET MULTILINE

PostPosted: Wed Dec 13, 2017 1:09 pm
by hmpaquito
Todo es sumable ;-)

Code: Select all  Expand view
Local lCambiado:= .f.

oGet:bChange = { || lCambiado:= .t. }

oGet:bLostFocus := {|| If(lCambiado, Graba(), nil) }
 

Re: GET MULTILINE

PostPosted: Wed Dec 13, 2017 1:18 pm
by acuellar
Gracias hmpaquito

Funciona Perfecto.