Adding year range to combo box

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ra220511
    New Member
    • Oct 2007
    • 11

    #1

    Adding year range to combo box

    im a bit rusty on my control properties

    can anyone remind me how i add a range of values from 1960 - 2007 for use with a year combo box (cboYear)
    with out have to add each value in individually through the collection area.

    i want the user to be able to select the year they were born rather than type it out
  • debasisdas
    Recognized Expert Expert
    • Dec 2006
    • 8119

    #2
    simply add in a for loop and then use the add item property

    try this sample

    for i = 1960 to 1970

    combobox1.addit em i

    next i

    Comment

    • ra220511
      New Member
      • Oct 2007
      • 11

      #3
      Originally posted by debasisdas
      simply add in a for loop and then use the add item property

      try this sample

      for i = 1960 to 1970

      combobox1.addit em i

      next i

      oh yeah see how rusty i am. didnt even think of that
      cheers

      Comment

      Working...