Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grab keyboard buffer data and store to text value
Message
De
19/11/2003 18:09:47
 
 
À
19/11/2003 17:48:07
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00851660
Message ID:
00851677
Vues:
9
Thanks Gunnar,

I was hoping (see my message to Sergey) to not have to create another function but I guess it will have to be!

Tracy

>Hello Tracy
>
>maybe i missunderstood you, but why don't you pass an object reference to the function, something like this:
>Return(RPMVALID(ab_rela, this))
>
>func RPMVALID
>   LPara ;
>      ValueToValidate, ;
>      ObjPointer
>   Local ;
>      ReturnValue
>
>   if ...validate, validate, validate = .t.
>      ObjPointer.Value = CHR(25) + LEFT(m.whatrelation,10)
>      ReturnValue = .t.
>   else
>      ReturnValue = .f.
>   endif
>   return(ReturnValue)
>endfunc
>
>>I have a form that replaces an FPD26 screen. In the old dos screen textbox's valid, code as below was run:
>>
>>
>>RETURN rpmvalid(ab_rela)
>>
>>
>>rpmvalid would validate the value of ab_rela and if not valid, provide a popup screen to select a valid value. The valid value selected from the popup screen was returned to the textbox via:
>>
>>KEYBOARD CHR(25) + LEFT(m.whatrelation,10)
>>
>>In the VFP form's valid method, this is not working. IF I use something similar to:
>>
>>
>>llreturn=RPMVALID(ab_rela)
>>IF llreturn
>>   RETURN .T.
>>ELSE
>>   RETURN 0
>>ENDIF
>>
>>
>>Then the next control's value following the textbox is populated with the keyboard buffer's data due to the RETURN .T. or RETURN 1. If I RETURN 0 if llreturn is .T. to stuff the textbox's value with the data in the keyboard buffer returned from the popup then of course I am stuck in the textbox control infinitely. I need to grab the value in the keyboard buffer and store it to the textbox's value and return .t. somehow. I can only see how to determine if the keyboard buffer has a value, not grab what it is using CHRSAW(). Any ideas?
>>
>>TIA,
.·*´¨)
.·`TCH
(..·*

010000110101001101101000011000010111001001110000010011110111001001000010011101010111001101110100
"When the debate is lost, slander becomes the tool of the loser." - Socrates
Vita contingit, Vive cum eo. (Life Happens, Live With it.)
"Life is not measured by the number of breaths we take, but by the moments that take our breath away." -- author unknown
"De omnibus dubitandum"
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform