Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Setfocus() not setting focus correctly
Message
 
 
To
27/01/2005 15:34:40
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows 2000 SP4
Database:
Visual FoxPro
Miscellaneous
Thread ID:
00981445
Message ID:
00981446
Views:
36
This message has been marked as the solution to the initial question of the thread.
Add
NODEFAULT
to prevent focus from moving to the next control.

>
> I have a form that contains the textbox - textbox1. In the lostfocus method, I have this code:
>
>local llok, lctext
>lctext = alltrim(this.value)
>thisform.moverlists1.lstSelected.ADDITEM(lctext)
>thisform.textbox1.setfocus()
>this.value = ""
>thisform.refresh()
>*!*	thisform.textbox1.setfocus()
>
>I had the setfocus after the this.value = "" and the textbox is not getting the focus.
> Yes, I am aware that at this moment, the user would never be able to get out of the box. I will fix that somehow. But I need the focus to go to the textbox and show a cursor until the user pushes one of two buttons.
>
>Thanks for your help.
>Beth
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform