Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP6SP5 - SetFocus to the first user control text, butt
Message
De
21/05/2003 09:11:59
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Allemagne
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00790342
Message ID:
00791017
Vues:
28
>This sort of thing may be of help...
>
>
>LOCAL lnLoop, lnClass,lnLoopPages, lnPagesControls, lcPageControlClass, lnPages
>WITH THISFORM
>	FOR lnLoop = 1 TO .CONTROLCOUNT
>		lcClass = UPPER(.CONTROLS[lnLoop].BASECLASS)
>		IF lcClass = "TEXTBOX" THEN
>			.CONTROLS[lnLoop].SETFOCUS
>		ENDIF
>		
>		IF lcClass ="PAGEFRAME" THEN
>			lnPages = .CONTROLS[lnLoop].PAGECOUNT
>			FOR lnLoopPages = 1 TO lnPages
>				FOR lnPagesControls = 1 TO .CONTROLS[lnLoop].PAGES[lnLoopPages].CONTROLCOUNT
>					lcPageControlClass = UPPER(.CONTROLS[lnLoop].PAGES[lnLoopPages].CONTROLS[lnPagesControls].BASECLASS)
>					IF lcPageControlClass == "TEXTBOX"
>						.CONTROLS[lnLoop].PAGES[lnLoopPages].CONTROLS[lnPagesControls].SETFOCUS()
>					ENDIF
>				ENDFOR
>			ENDFOR
>                ENDIF
>	ENDFOR
>ENDWITH
>
>
>but you would still probably need to set some property on the first control so that you have some way of identifying it in the controls collection.
>

TABINDEX may be what your looking for
>HTH
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord

Weeks of programming can save you hours of planning.

Off

There is no place like [::1]
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform