473,398 Members | 2,212 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,398 software developers and data experts.

How to set focus on a label after a button clicked (web applicatio

Hi, all:

I have a label "ID=lblTotal" in my aspx page and also have a button
"ID=btnTotal"
I would like to click total button and show the result on the label and set
focus on the label. Now, when I click the button, the result shows on the
label, but the cusor will go to the top of the page, which I have drag the
page down to see the result.

How should I do it? I think javascript is needed here, but how? (I am using
vb.net for this web App.)
Jul 21 '05 #1
2 6843
if you are not familar with javascript, why not use anchor to insteal of it

Tony
"Symphony" <Sy******@discussions.microsoft.com> wrote in message
news:7D**********************************@microsof t.com...
Hi, all:

I have a label "ID=lblTotal" in my aspx page and also have a button
"ID=btnTotal"
I would like to click total button and show the result on the label and set focus on the label. Now, when I click the button, the result shows on the
label, but the cusor will go to the top of the page, which I have drag the
page down to see the result.

How should I do it? I think javascript is needed here, but how? (I am using vb.net for this web App.)

Jul 21 '05 #2
if I use anchor, I will lost all the info. the user just typed in, Can I use
anchor and also keep the info. that user just typed in? Thanks.

"Tony" wrote:
if you are not familar with javascript, why not use anchor to insteal of it

Tony
"Symphony" <Sy******@discussions.microsoft.com> wrote in message
news:7D**********************************@microsof t.com...
Hi, all:

I have a label "ID=lblTotal" in my aspx page and also have a button
"ID=btnTotal"
I would like to click total button and show the result on the label and

set
focus on the label. Now, when I click the button, the result shows on the
label, but the cusor will go to the top of the page, which I have drag the
page down to see the result.

How should I do it? I think javascript is needed here, but how? (I am

using
vb.net for this web App.)


Jul 21 '05 #3

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

Similar topics

7
by: Chris | last post by:
I'm using eight links listed horizontally as a menu on my site. I'm using font-variant:small-caps and they are padded so that they mimic buttons. My gripe is with the way IE handles the focus...
0
by: Symphony | last post by:
Hi,all: I am using vb.net develop a web application. On one form(form1) I have a button called "calculate total" and a lable call "total", after click "calculate total", the total amount will...
1
by: PK9 | last post by:
On my page, I want to set the focus to the top of the page (where I have a message in a label) after a button is clicked. How can I use javascript on the server side to set the focus either to a...
8
by: Yeah | last post by:
I wish to use a drop box where each Option will not take the user to a web page - but a certain location on the same page the drop box exists. For example, Option 1 would take the user to "Chapter...
2
by: Symphony | last post by:
Hi, all: I have a label "ID=lblTotal" in my aspx page and also have a button "ID=btnTotal" I would like to click total button and show the result on the label and set focus on the label. Now,...
16
by: Stuart | last post by:
I have a page where I utilise the left and right cursor keys to change an image, also on this page is a groups of radio buttons, unfortunately when a radio button is clicked the focus for the...
11
by: Alex.Svetos | last post by:
Hello, I'm trying to get a popup to keep focus when it is re-clicked. The script below is supposed to produce this exact behaviour, however it doesn't work, at least on firefox 1.0.7 and moz...
4
by: pablorp80 | last post by:
Hello, Here is what I need: I need the focus and the cursor set to a textbox named txtGT, every time no matter if it is the first page load or whether it is a postback. Here is the problem: I...
1
by: karthik25 | last post by:
Hi, The following code creates a tab container, 5 tab panels, buttons, labels. I was able to add event handlers to the button. But how am i supposed to access the dynamically created labels? For...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
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.