Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Setfocus based on Tab Order = 1?
Message
From
10/11/1997 21:07:04
 
 
To
10/11/1997 20:50:07
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00059420
Message ID:
00059439
Views:
34
>>Is it possible to detect which control has a tab order of "1" and to set focus to that control?
>
>lnMin = 9999
>
>FOR lnI = 1 TO _Screen.ActiveForm.ControlCount
> IF _Screen.ActiveControl.TabIndex < lnMin
> lnMin = _Screen.ActiveControl.TabIndex
> loControl = _Screen.ActiveControl
> ENDIF
>ENDFOR
>
>loControl.SetFocus()

How do you set the focus to a Label object? What if the object is disabled?

Besides, you should use ActiveForm.Controls[lnI] instead of ActiveControl.

Vlad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform