Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Avoid having pageframe on TAB #1
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00016833
Message ID:
00017030
Views:
79
>
>PROCEDURE SetFirst
>* Sets focus to control with earliest TabIndex
>
>LPARAMETER toWhich
>LOCAL loCtl, loPag
>
>IF PCOUNT() < 1
>    toWhich = thisForm	
>ENDif
>
>FOR EACH loCtl IN toWhich.Controls
>    WITH loCtl
>        IF .TabIndex = 1
>            .SetFocus()
>            EXIT
>        ENDif
>        IF UPPER(.baseClass) = "PAGEFRAME"
>            FOR EACH loPag IN .Pages
>                IF  loPag.PageOrder = .ActivePage
>                    thisForm.SetFirst(loPag)
>                ENDif
>            ENDfor
>        ENDif
>    ENDwith
>ENDfor
>ENDproc
>
Thanks, I have saved this in my code folder and will make good use of it when needed.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform