473,396 Members | 1,895 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Need to find which text box has the focus.

I have an aspx form with 52 text boxes, each one representing a week.

On another part of the form I have a further 7 text boxes, each
representing a day of the week.

I'd really like to be able to mimic the functionality in the VB6
program on which this is based, which is:

When a text box gets the focus, the "day" text boxes are refreshed to
show the daily data for that week.

I realise that in ASP.NET this might provide a sub-optimal user
experience, as there would need to be a postback each time the "day"
text boxes was refreshed.

As a compromise I propose adding a "Refresh" button on the form, that
would determine which weekly text box has the focus, and refresh the
"day" text boxes accordingly.

Anyone got any ideas how to do this?

Many thanks in advance

Edward

Jan 19 '06 #1
1 1163
Use javascript or vbscript on the client side, you have exposure to many
events.

OnBlur
OnFocus
OnFocusIn
OnFocusOut
OnActivate
OnDeactivate

you may also use document.activeElement

<te********@hotmail.com> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com...
I have an aspx form with 52 text boxes, each one representing a week.

On another part of the form I have a further 7 text boxes, each
representing a day of the week.

I'd really like to be able to mimic the functionality in the VB6
program on which this is based, which is:

When a text box gets the focus, the "day" text boxes are refreshed to
show the daily data for that week.

I realise that in ASP.NET this might provide a sub-optimal user
experience, as there would need to be a postback each time the "day"
text boxes was refreshed.

As a compromise I propose adding a "Refresh" button on the form, that
would determine which weekly text box has the focus, and refresh the
"day" text boxes accordingly.

Anyone got any ideas how to do this?

Many thanks in advance

Edward

Jan 19 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: George Hester | last post by:
In a page I have when the user left-clicks the page a Input box for a form gets the focus. But if the user right-clicks the page the Input box is not getting the focus. I'd like the Input box to...
9
by: CW | last post by:
I wrote an HTML based chat application. The front end is built entirely on HTML + javascript. Essentially, I have a hidden frame that's refreshed frequently and any new messages are displayed in...
18
by: Euphor2 | last post by:
I'm in school, taking a VB .NET 2003 course, and the teacher taught us how to use Sender.Focus() to return focus to the control from which focus was received. However, when I got home, and tried...
1
by: teddysnips | last post by:
I have an aspx form with 52 text boxes, each one representing a week. On another part of the form I have a further 7 text boxes, each representing a day of the week. I'd really like to be able...
4
by: newbie | last post by:
Hi, I have a windows form written in C#. The form has multiple textboxes and multiple buttons. I want to create a form where when the users clicks on a particulat textbox and then clicks on a...
20
by: mike | last post by:
I help manage a large web site, one that has over 600 html pages... It's a reference site for ham radio folks and as an example, one page indexes over 1.8 gb of on-line PDF documents. The site...
3
Frinavale
by: Frinavale | last post by:
I've been searching for a little while now and can't figure out how to determine if a particular element has focus. I'm changing either a text box representing the Hours in time or Minutes in time...
2
by: dougmcmurtry | last post by:
I have a web app that is going on a touch screen computer with no keyboard, so I have to allow them to enter numeric data into text fields through a UserControl that I built. All I need to find is...
10
by: Gary | last post by:
I'm trying to find a way to determin which window Within-Another-Program currently has the focus. THE SITUATION: (Skip down to "My Question" if you don't want the background...) * This is...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.