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

Highlight NumericUpDown field after tab

How do you highlight (or select) the value of a numeric field after
you to this field.
Aug 22 '08 #1
4 3333
On Aug 22, 10:50*am, JoCom67 <joco...@gmail.comwrote:
How do you highlight (or select) the value of a numeric field after
you to this field.
After you what do to this field?
Aug 22 '08 #2
On Aug 22, 2:41 pm, za...@construction-imaging.com wrote:
On Aug 22, 10:50 am, JoCom67 <joco...@gmail.comwrote:
How do you highlight (or select) the value of a numeric field after
you to this field.

After you what do to this field?
Coming from another field, once the tab key is pressed, it should
select (highlight) the numeric value so that when the user types in
the new value it will just override or overwrite the previous numeric
value of this field.
Aug 25 '08 #3
On Aug 25, 4:19 pm, JoCom67 <joco...@gmail.comwrote:
On Aug 22, 2:41 pm, za...@construction-imaging.com wrote:
On Aug 22, 10:50 am, JoCom67 <joco...@gmail.comwrote:
How do you highlight (or select) the value of a numeric field after
you to this field.
After you what do to this field?

Coming from another field, once the tab key is pressed, it should
select (highlight) the numeric value so that when the user types in
the new value it will just override or overwrite the previous numeric
value of this field.
Pressing TAB brings you to NumericUpDown control normally, then all
you have to do is to handle GofFocus event as follows:
' Code Lines are splitted for a proper paste
' Select entire value
Private Sub NumericUpDown1_GotFocus _
(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles _
NumericUpDown1.GotFocus
NumericUpDown1.Select(0, _
NumericUpDown1.Value.ToString.Length)
End Sub
Hope this helps,

Onur Güzel
Aug 25 '08 #4
On Aug 25, 10:43 am, kimiraikkonen <kimiraikkone...@gmail.comwrote:
On Aug 25, 4:19 pm, JoCom67 <joco...@gmail.comwrote:
On Aug 22, 2:41 pm, za...@construction-imaging.com wrote:
On Aug 22, 10:50 am, JoCom67 <joco...@gmail.comwrote:
How do you highlight (or select) the value of a numeric field after
you to this field.
After you what do to this field?
Coming from another field, once the tab key is pressed, it should
select (highlight) the numeric value so that when the user types in
the new value it will just override or overwrite the previous numeric
value of this field.

Pressing TAB brings you to NumericUpDown control normally, then all
you have to do is to handle GofFocus event as follows:

' Code Lines are splitted for a proper paste
' Select entire value
Private Sub NumericUpDown1_GotFocus _
(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles _
NumericUpDown1.GotFocus
NumericUpDown1.Select(0, _
NumericUpDown1.Value.ToString.Length)
End Sub

Hope this helps,

Onur Güzel
Thanks Onur, I tried it and it worked. Again Thanks!
Aug 25 '08 #5

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

Similar topics

21
by: | last post by:
Hi, I am setting the NumericUpDown .Value property and the ValueChanged event is NOT being fired. Does this ONLY get fired when I change it on the UI and not programatically? Thanks
1
by: Not Me | last post by:
Hey, In our database, we have implemented auditing simply by holding a copy of each row of the specific table at any time that data is updated. This gives us a long list of full records, often...
10
by: Bonj | last post by:
I'm using a number of NumericUpDown controls on my form, which controls printer settings such as number of pages. However I want to override one of the default behaviours of the control, namely...
0
by: Koert | last post by:
Hi In the NumericUpDown control I have to detect that Tab was pressed so I have inherited the NumericUpDown and overroden the PreProcessMessage function. In the DateTimePicker (for example) this...
3
by: abc my vclass | last post by:
My win-form have many numericupdown controls to applied. But numericupdown control don't like textbox, text box control can automatic selected text when got focus. Is there any method can let me...
4
by: illegal.prime | last post by:
Hey all, I have a NumericUpDown control on a Panel or potentially a Form that have AutoScroll enabled. When the NumericUpDown is active I would like the Form/Panel/whatever not to scroll when I...
5
by: Len Weltman | last post by:
I am trying to pass a NumericUpDown object into a class method using Visual Studio 2005, but the control type is not found in Intellisense and the type declaration is flagged as an error. Here...
2
by: Stephan Zaubzer | last post by:
Hi all, I encountered a problem with NumericUpDown yesterday and managed to reproduce the error with a very easy examle. I have a Windows Application with only one Form, which contains only one...
2
by: =?Utf-8?B?U2hhcm9u?= | last post by:
Hello experts, I posted a disturbing question in here:...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
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
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
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: 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
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
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?

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.