Wrapping entries in a ListBox
I have a macro that takes cell data from a spreadsheet and populates a
ListBox. I have no problems getting the data I want into the ListBox, but I'd like to make it look neater. Many of the items I add are longer than the width of the ListBox. I'd like to wrap (and possibly indent?) such entries, but I can't find a WordWrap property for the ListBox in the Properties window. Does anyone know a way to do this? |
Wrapping entries in a ListBox
To the best of my knowledge, you cannot have multiline items in a ListBox
(without horizontal "grid" lines, I think it would be complicated to read). However, assuming you are using an ActiveX control and not one from the Forms toolbar, you can implement a horizontal scroll bar so the that the long items can be read in their entirely... just set a ColumnWidths property to a number of points large enough to allow the scroll bar to reveal all of the text (you can do that by trial and error). -- Rick (MVP - Excel) "Luke" wrote in message ... I have a macro that takes cell data from a spreadsheet and populates a ListBox. I have no problems getting the data I want into the ListBox, but I'd like to make it look neater. Many of the items I add are longer than the width of the ListBox. I'd like to wrap (and possibly indent?) such entries, but I can't find a WordWrap property for the ListBox in the Properties window. Does anyone know a way to do this? |
All times are GMT +1. The time now is 05:13 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com