Results 1 to 2 of 2

Thread: Implementing a combobox

  1. #1

    Thread Starter
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704

    Implementing a combobox

    One thing I really think should be added to a combobox, is a menuTitle property, that displays a directive to a user such as "Select A City", or "Select A Color".

    What I mean is this: If you set a combobox's datasource property to a dataset, you use a directive to display to the user since it does not exist in the dataset.

    Now, some would say, just add "Select A City" to the dataset, and check for it to prevent errors, but that's not really practical when you need to pump out 45 forms.

    But it is practical if you do inside the control itself. So, I need to create an Inherited combobox, that will somehow do a switcheroo.

    In case I haven't been clear...
    If you have four items in a dataset, how would you reset the combobox to display "Select An Item". And while its displaying "Select An Item", its selectedindex=-1. So if the user selects an item, then decides to deselect it, they can simply select "Select An Item", and I as a programmer know they have not entered a selection from that combobox.-------+

  2. #2

    Thread Starter
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704
    That sounded confusing, may be I can explain it better with a simple project.... when it loads, it sets the combobox to -1, but when you press the button to reset the combobox, it simply selects an item in its list (usually descending until it hits the first element, but never reverts to unselected.)
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width