Results 1 to 3 of 3

Thread: ComboBox Array

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2005
    Location
    Sandviken Sweden
    Posts
    2

    Question ComboBox Array

    Hi All
    I've been trying to populate a combobox with an array of all the month of the year, but with no luck.
    There is probably a simpel task if you know how
    I'm doing this in Excel 97 and I would like to use VBA rather than a cell range.
    All help are appreciated
    Thanks
    Last edited by [nordis]; Jan 17th, 2005 at 06:59 AM.

  2. #2
    Fanatic Member Comintern's Avatar
    Join Date
    Nov 2004
    Location
    Lincoln, NE
    Posts
    826

    Re: ComboBox Array

    Try this, where ComboBox1 is your control:

    VB Code:
    1. For iCount = 1 To 12
    2.     ComboBox1.AddItem (Format$(DateAdd("m", iCount, 0), "mmmm"))
    3. Next iCount

  3. #3

    Thread Starter
    New Member
    Join Date
    Jan 2005
    Location
    Sandviken Sweden
    Posts
    2

    Re: ComboBox Array

    Thanks Comintern
    I'll try that

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