473,385 Members | 1,983 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,385 software developers and data experts.

HELP : regarding Textbox Enter and Focus Question many TIA

Hi ,
I did ask before but got no replies.

I have a series of textboxes, In Enter event I need to set the focus to a different textbox
I am having problems when I set focus within the Textbox Enter event.
It is looping thru the events.

Does anyone know how I can set focus to another object when the Textbox has
received focus either by keyboard or mouse event.

THANK YOU.
Nov 16 '05 #1
3 1533
Maybe you can tell us more (or more specifically) what you need to
accomplish?
Are you trying to prevent certain textboxes from getting the focus?

<Co**********@al.com> wrote in message
news:cu**********@news7.svr.pol.co.uk...
Hi ,
I did ask before but got no replies.

I have a series of textboxes, In Enter event I need to set the focus to a
different textbox
I am having problems when I set focus within the Textbox Enter event.
It is looping thru the events.

Does anyone know how I can set focus to another object when the Textbox
has
received focus either by keyboard or mouse event.

THANK YOU.

Nov 16 '05 #2
I would just hook into the key up event. It will be the last event that
is fired when a key si pressed in the textbox. When you find out that it is
the enter key, you just have to call the GetNextControl method on the
current control to find the next control in the tab order. Then call the
Focus method on that control to set the focus.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

<Co**********@al.com> wrote in message
news:cu**********@news7.svr.pol.co.uk...
Hi ,
I did ask before but got no replies.

I have a series of textboxes, In Enter event I need to set the focus to a
different textbox
I am having problems when I set focus within the Textbox Enter event.
It is looping thru the events.

Does anyone know how I can set focus to another object when the Textbox
has
received focus either by keyboard or mouse event.

THANK YOU.

Nov 16 '05 #3
Setting the focus to another control in the Enter-event disables the first
control of getting the focus.

Maybe you should give us some extra information on what you want to do?

"Co**********@al.com" wrote:
Hi ,
I did ask before but got no replies.

I have a series of textboxes, In Enter event I need to set the focus to a different textbox
I am having problems when I set focus within the Textbox Enter event.
It is looping thru the events.

Does anyone know how I can set focus to another object when the Textbox has
received focus either by keyboard or mouse event.

THANK YOU.

Nov 16 '05 #4

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

Similar topics

3
by: Randi | last post by:
Hi All, I have a problem on a username password login form. I use: txtPassword.Text = StrConv(txtPassword.Text, vbProperCase) to validate the proper case when someone enters their name and...
9
by: Megan | last post by:
Hi- I'm creating a database of music bands with their cds and songs. I'm trying to program an SQL statement so that I can enter a string of text in a textbox, press the 'Enter' key, and have...
1
by: geneb | last post by:
I've got a number of tabs with text boxes on them. When you hit the last textbox on a tab, it checks to see if the next tab is a valid destination, then goes to it if so. Unfortunately, when...
4
by: melanieab | last post by:
Hi, Sorry this is a long message, but I'm getting desperate (and worried). I have a textbox (say, tb1) where the string is longer than the width of the box. If I'm coming from the previous...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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...

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.