Solved

Need advice to display selections: Infinite, 30 to 99999

Posted on 2013-05-15
4
164 Views
Last Modified: 2013-05-21
Hi experts
I would like some advice on a proper way to display in Winform the following:
They need to be data-bound to an object such that "Infinite" is represented by integer '0', "30" as '30', etc. (ie. 1...29 are prohibited.)

   Infinite
   30
   31
    :
    :
   99999

I guess I have two options: comboBox or domainUpDown.
Is it possible that when user types "I" or "i", then "Infinite" shows up immediately?

Thanks in advance.
0
Comment
Question by:dominicwong
  • 3
4 Comments
 
LVL 79

Assisted Solution

by:David Johnson, CD, MVP
David Johnson, CD, MVP earned 200 total points
ID: 39170278
What you need and what you display are 2 separate items.  
0 will display 0 unless you override it and tell it to display infinite.. you also need to do the converse if the user enters Infinite then you pass back to the backend a 0.  You also need data validation to ensure the range of 1-29 is excluded.. or returned back to the user as an error.
0
 

Author Comment

by:dominicwong
ID: 39170369
Could you elaborate the meaning of 2 separate items. Thanks
0
 

Accepted Solution

by:
dominicwong earned 0 total points
ID: 39173681
Used a comboBox and bound it to a Dictionary.
0
 

Author Closing Comment

by:dominicwong
ID: 39183820
Managed to resolve it by using a comboBox and Dictionary.
Thanks anyway though.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

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

Suggested Solutions

A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

831 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