Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / C# / February 2008

Tip: Looking for answers? Try searching our database.

Simple? Problem With Numeric Up/Down Control

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
joey.powell@topscene.com - 25 Feb 2008 15:56 GMT
Hello guys. I have a Windows forms app where I need to use a couple of
numeric up/down controls. I am having a problem with them because I
cannot set the control to ReadOnly (I need for users to be able to use
the keyboard) but when users highlight all of the text and hit
backspace, all text is removed from the "textbox" portion of the
control. This control does not have ".Text" property like normal
textboxes; it has a "Value" (Decimal) property instead. Now this
creates a problem when users are able to "delete" all text from the
control. Even if they tab out to the next control, the value appears
empty. But in debug mode I can see that the value is actually still
there, although it doesn't show.

How can I force it to show...like maybe in the control's Leave event?
I have tried lots of things....Show(). .Refresh() etc...

What can I do?

Also, do you guys have any ideas on how to format the display (for
whole numbers)? For example...make 2 appear as 002?
not_a_commie - 25 Feb 2008 17:26 GMT
The winforms NumericUpDown control is buggy. It's validate and focus
handlers are screwed up. You will need to write your own NumericUpDown
control, though you can use NumericUpDownBase as the base class as it
appears to work well.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.