How to Create a Multi-Column List Box in Excel VBA
Question details
The user needs to know how to create and configure a list box in VBA that can display data across multiple columns.

- Product
- Excel / WPS Spreadsheet
- Device & OS
- Windows, macOS
- Scenario
- Developing a custom UserForm or interactive worksheet interface using VBA where data needs to be presented in a structured, multi-column format.
- Observed behavior
- Requires step-by-step property configuration for Windows VBA and an explanation of interface limitations and alternatives for macOS environments.
Ensure your Developer tab is enabled in your spreadsheet application and verify your operating system, as ActiveX controls used for advanced list boxes are only fully supported on Windows.
Configure a Multi-Column List Box in a Windows VBA UserForm
Use the VBA Editor in Windows to configure an ActiveX ListBox control with specific column counts, widths, and a defined data source.
In a Windows environment, VBA provides full support for ActiveX controls. You can easily adjust the properties of a ListBox within a UserForm to accommodate multiple columns of data.
Press ALT + F11 on your keyboard to open the Visual Basic for Applications (VBA) Editor, then insert a new UserForm from the Insert menu.
Display the Toolbox, click on the ListBox icon, and draw the control onto your newly created UserForm.
Select the ListBox, locate the Properties window on the left side, find the 'ColumnCount' property, and change the value to your desired number of columns (e.g., 3).
In the same Properties window, find the 'ColumnWidths' property and specify the widths separated by semicolons (for example, '50 pt; 50 pt; 50 pt') to ensure all data is visible.
Locate the 'RowSource' property and enter the named range or address of your data on the worksheet (e.g., 'Sheet1!A1:C10') to populate the list box automatically.

Implement Alternative Form Controls on macOS
Use standard Form Controls and data helpers on a Mac, as ActiveX controls are restricted due to macOS security policies.
Create Advanced VBA UserForms with WPS Office
WPS Spreadsheet provides a robust, built-in VBA environment that natively supports ActiveX controls on Windows. You can easily build custom UserForms, configure multi-column list boxes, and write macros just as you would in Microsoft Excel.
- 1. Access the VBA Environment: Open WPS Spreadsheet, navigate to the Developer tab, and click on 'VBA Editor' to launch the visual development interface.
- 2. Design Your UserForm: Click 'Insert' > 'UserForm' and use the Toolbox to drag and drop a ListBox control onto your canvas.
- 3. Configure Multi-Column Settings: Use the Properties panel to adjust the ColumnCount, ColumnWidths, and RowSource exactly as you would with standard Excel macros.
- 4. Run and Test: Press F5 or click the Run button to launch your UserForm and interact with your multi-column list box seamlessly.

Frequently Asked Questions
Why isn't my multi-column list box working on my Mac?
Multi-column list boxes built using ActiveX controls are natively unsupported on macOS due to system-level security restrictions. To resolve this, you will need to use standard Form Controls or concatenate your data into a single helper column on the worksheet.
How do I populate a multi-column list box programmatically in VBA without using RowSource?
You can assign a 2D array directly to the '.List' property of the list box. Alternatively, use the '.AddItem' method to create a new row, and then populate the additional columns of that row using '.List(ListIndex, ColumnIndex) = Value'.
Can I add headers to my VBA multi-column list box?
Yes, you can enable headers by setting the 'ColumnHeads' property to True in the Properties window. However, this feature only works when you populate the list box using the 'RowSource' property linked directly to a worksheet range.
Why is only the first column visible even though I set the ColumnCount to 3?
This usually happens if the total width of the columns exceeds the visual width of the list box, or if the 'ColumnWidths' property is incorrectly formatted. Ensure you specify widths for all columns using points (e.g., '50;50;50') in the Properties window.




