Results 1 to 5 of 5
  1. #1
    Join Date
    Dec 2010
    Posts
    21

    Question Unanswered: how to choose max from combobox vb.net

    i want to choose the maximum value from the combo box in the vb.net.?
    i have items already added. so i want to take a decision to take largest of them when i have integer data only.

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    iterate through the combo box
    forget the details
    look at the combo box properties and iterate though the collection holding the values
    bear in mind the columns property starts at base 0 so if you have two columns per row in the combo the first column is actually column(0)
    I'd rather be riding on the Tiger 800 or the Norton

  3. #3
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    What did you bind the combo box to?
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  4. #4
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    of course the 'other' technique would be to declare a form variable andset that to the maximum value each time you tinker with the combo box
    I'd rather be riding on the Tiger 800 or the Norton

  5. #5
    Join Date
    Aug 2004
    Location
    Dallas, Texas
    Posts
    831
    Try listindex(-1) <-- puesdo code....

Posting Permissions

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