Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set focus question
Message
De
05/03/1999 12:00:14
 
 
À
05/03/1999 10:37:49
Brad Stickley
Parker Pneumatic Div. North America
Wake Forest, Caroline du Nord, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00194489
Message ID:
00194557
Vues:
26
>>I have a form that has a txt box on it. When the operator types a number not in the table, I want the focus to return back to the box so they can re-type another one.
>>I have the select on entry to T so that the whole value is highlighted when the object has focus.
>>
>>I am getting an error with this.
>>
>>Any suggestions?
>>
>>Thanks in advance.
>
>oops, here is the code
>
>SELECT saw_data_table
> SET order to column1
> IF ! seek(UPPER(alltrim(this.value)))
> MESSAGEBOX("That part is not on Record")
> THISFORM.Text2.SetFocus
> ELSE
> thisform.refresh()
>ENDIf


I assume the error you are getting is "can't use SetFocus from Valid...".

If this code is in your Valid method, return a 0 (zero) to not move to the next control (no VFP message) or return .F. to prevent movement with a VFP message (Invalid...)
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform