Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > Focus

Reply
Thread Tools

Focus

 
 
Liliana
Guest
Posts: n/a
 
      12-24-2003
I am creating an asp.net page.
When this page is loaded I need the focus to be on a text box.
(The user will use a barcode scanner to scan some data in the text
box).
Also when the focus moves to another textbox on the page I need to do
some processing of the string that was entered in the first textbox.
Please let me know if this is possible and how.

Thank you,

Liliana
 
Reply With Quote
 
 
 
 
Alessandro Zifiglio
Guest
Posts: n/a
 
      12-24-2003
hi Liliana,
Despite the lack of a server-side Focus property on Web Controls, you can create a custom FocusManager Web Control that sets the focus to any other control on the page that you choose. You specify which control should receive the focus with a String property called BoundControlID. This will require some work, follow the article I've pasted below. The end product is a custom web control you can use on your pages to set focus on any element you choose. As for the processing you need to do when focus is moved to another element in your case another textbox, that you will have to code yourself, again in javascript. All these events take place on the client. Javascript is the way to go.
Heres the link to the FocusManager Web Control :
http://archive.devx.com/dotnet/artic...rj121801-1.asp

Merry christmas


"Liliana" <(E-Mail Removed)> wrote in message news:(E-Mail Removed) om...
> I am creating an asp.net page.
> When this page is loaded I need the focus to be on a text box.
> (The user will use a barcode scanner to scan some data in the text
> box).
> Also when the focus moves to another textbox on the page I need to do
> some processing of the string that was entered in the first textbox.
> Please let me know if this is possible and how.
>
> Thank you,
>
> Liliana

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
this.window.focus() vs. window.focus() vs. this.focus() Roger Javascript 3 03-08-2007 08:53 PM
Why "Focus and Recompose" causes back-focus issues Carl Miller Digital Photography 7 03-10-2005 12:14 PM
Fuji EXIF: Focus warning: "Out of focus" Hasan Diwan Digital Photography 3 12-26-2004 04:13 AM
Pan Focus vs Auto Focus JethroUK© Digital Photography 2 08-11-2004 06:26 PM
any manual focus cameras easy to focus? Catherine Jo Morgan Digital Photography 6 11-05-2003 06:36 PM



Advertisments