> Hello,
> I am having difficulty in setting focus on the control I need.
>
> Here is the situatuion.
>
> On my form, I have a textbox that accepts only scans and a button. The button is not enabled until the scan happens.
> There are no keyboard or mouse - just a barcode scanner and a touch screen.
>
> The button should only appear after the barcode is scanned and verified. At this point my barcode is saved and the textbox is cleared. Button only should serve as an available option.
>
> My problem is to return the focus to the textbox and not have it on the button at all.
>
> I am trying to use Control.SetFocus but it doesn't work...
>
> Thank you for your help.
>
>
>
> AG
*Textbox Lostfocus
* code ... if any
if ScanIsValid
* no problem, let it go
else
NODEFAULT
this.SetFocus()
endif
Cetin Basoz
.Net has got better.Think about moving - check my blog:
Blog (main)Blog (mirror)