+ Reply to Thread
Results 1 to 6 of 6

Using Array as Rowsource in Userform

  1. #1
    Registered User
    Join Date
    10-08-2014
    Location
    Lake Havasu City, AZ
    MS-Off Ver
    Office 365
    Posts
    23

    Using Array as Rowsource in Userform

    I am trying to use an array for the rowsource value in the listbox for a userform. I think my array code is correct, but the listbox.rowsource doesn't like the array name as the value. I am populating my array with the sheet names and trying to fill the list box with that array. Here is my code:

    Please Login or Register  to view this content.
    How do I reference the array in rowsource in the properties explorer?

    Thanks,

    John W

  2. #2
    Forum Guru Izandol's Avatar
    Join Date
    03-29-2012
    Location
    *
    MS-Off Ver
    Excel 20(03|10|13)
    Posts
    2,581

    Re: Using Array as Rowsource in Userform

    Rowsource may only be address of a range. You may use List property with arrays.
    • Please remember to mark threads Solved with Thread Tools link at top of page.
    • Please use code tags when posting code: [code]Place your code here[/code]
    • Please read Forum Rules

  3. #3
    Registered User
    Join Date
    10-08-2014
    Location
    Lake Havasu City, AZ
    MS-Off Ver
    Office 365
    Posts
    23

    Re: Using Array as Rowsource in Userform

    Thanks for your quick reply.

    Would the syntax be:

    Please Login or Register  to view this content.

  4. #4
    Forum Guru Izandol's Avatar
    Join Date
    03-29-2012
    Location
    *
    MS-Off Ver
    Excel 20(03|10|13)
    Posts
    2,581

    Re: Using Array as Rowsource in Userform

    Yes - this must be before line to show form

  5. #5
    Forum Expert
    Join Date
    07-31-2010
    Location
    California
    MS-Off Ver
    Excel 2007
    Posts
    4,070

    Re: Using Array as Rowsource in Userform

    Surprised you didn't' just try it. It should work.
    If you are happy with my response please click the * in the lower left of my post.

  6. #6
    Registered User
    Join Date
    10-08-2014
    Location
    Lake Havasu City, AZ
    MS-Off Ver
    Office 365
    Posts
    23

    Re: Using Array as Rowsource in Userform

    Thanks for your help

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Userform RowSource
    By plans in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-12-2015, 11:46 AM
  2. [SOLVED] Userform and Rowsource
    By saban1974 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 06-06-2014, 12:44 PM
  3. [SOLVED] Dynamic RowSource in Combox1 UserForm
    By WimpieOosthuizen in forum Excel General
    Replies: 3
    Last Post: 06-04-2014, 05:19 AM
  4. [SOLVED] VBA Userform combobox rowsource and folder value help
    By ds16 in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 07-27-2012, 03:03 PM
  5. UserForm/ RowSource (using combo boxes)
    By Squirrel in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-31-2011, 05:23 PM
  6. ???Help??? Userform.Listbox.rowsource = ???
    By Steve Sparti in forum Excel General
    Replies: 0
    Last Post: 03-01-2006, 05:50 PM
  7. UserForm ComboBox RowSource Question
    By Minitman in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 11-15-2005, 03:10 PM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1