ListBox Column Format

jstevens
GoldLounger
Posts: 2618
Joined: 26 Jan 2010, 16:31
Location: Southern California

ListBox Column Format

Post by jstevens »

Is it possible to format Listbox amount columns so that the decimal places line up? The information for the Listbox is in a worksheet.

Example of Listbox contents: RowSource=MySheet!A1:D10
EL_106.png
You do not have the required permissions to view the files attached to this post.
Regards,
John

User avatar
HansV
Administrator
Posts: 78237
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: ListBox Column Format

Post by HansV »

You can set the TextAlign property of the Listbox to 3 - fmTextAlignRight.
This will be applied to all columns of the ListBox.
Best wishes,
Hans

jstevens
GoldLounger
Posts: 2618
Joined: 26 Jan 2010, 16:31
Location: Southern California

Re: ListBox Column Format

Post by jstevens »

Hans,

Since the Listbox RowSource is coming from a sheet, I turned the values into text and formatted the cells accordingly by VBA.
Regards,
John