Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP 5.0 & SetFocus()
Message
De
17/12/1996 15:41:14
Paul Watson
Mcv Global Systems, Inc.
Pasadena, Californie, États-Unis
 
 
À
17/12/1996 15:30:46
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00015359
Message ID:
00015399
Vues:
47
I made a few minor changes and plugged it into my routine as follows:

* Force the Valid() event for the current prompt...
IF TYPE('ThisForm.ActiveControl') = 'O'
*-- Can't use SetFocus() if called from a Valid() or Activate() Method.
LOCAL lcProgram,lnCompteur,llOkayToSetFocus
lcProgram=PROGRAM(1)
lnCompteur=2
llOkayToSetFocus = .T.
DO WHILE LEN(lcProgram)>0
lcProgram=EVALUATE('PROGRAM('+ALLTRIM(STR(lnCompteur))+')')
lnCompteur=lnCompteur+1
IF INLIST(UPPER(RIGHT(lcProgram,6)), '.VALID', 'WHEN', 'ACTIVATE')
llOkayToSetFocus = .F.
EXIT
ENDIF
ENDDO
IF llOkayToSetFocus
ThisForm.ActiveControl.SetFocus()
ENDIF
ENDIF


It works perfectly! Thanks again.
Paul Watson
MCV Computer Consultants
MCV Global Systems, Inc.
pWatson@PrimeNet.Com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform