?
Solved

Numeric Up/Down Control - Select all text

Posted on 2006-10-23
2
Medium Priority
?
419 Views
Last Modified: 2008-01-09
Hi experts,

I'm using a Numeric Up/Down control and have managed to get the application to select all text when the focus passes to the control at run time.  With normal text boxes this is easily achieved with a .SelectAll function.  With the Numeric Up/Down control I have achieved it using the following code:

        ' Select all text.
        txtTransitionAltitude.Select(0, Len(txtTransitionAltitude.Value))

I now want to have all text selected when I increase of decrease the value using the up/down buttons but cannot get it to work.  I used the above code in the _ValueChanged sub but only a flash of the selection occured when I tried it out.  

Is there another way I can do this?  

Regards,

Ady
0
Comment
Question by:Ady Foot
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 9

Accepted Solution

by:
DjDezmond earned 500 total points
ID: 17787328
In the design window, goto the _valueChange sub and copy and code into the:

_MouseUp

or

_KeyUp

Event for that control. Your code accesses the value of that control, but when valuechanged is handeled, the value has changed, so it can't reference it. Using on of the above two should work how you need it to.

Dez
0
 
LVL 16

Author Comment

by:Ady Foot
ID: 17787335
Spot on - thanks!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question