Concantenate and align info??
I am trying to concantenate information from three columns into one s
that the info contained in the three columns can be viewed on a use form. The form works great but because the cells hold information o different lengths it displays the information all unaligned as below: h1&" "h2&" "h3 $14 blah blah etcetc $142 blah blah etcetc $1433 blahblah etcetc Is it possible to establish the string lenth for each h instead o trying to make it space so that the information would align? I thank you in advance for any suggestions -- Message posted from http://www.ExcelForum.com |
Concantenate and align info??
One way:
Dim h As String h = Left(h1 & Space(20), 20) & Left(h2 & Space(20), 20) & h3 In article , depuyus wrote: I am trying to concantenate information from three columns into one so that the info contained in the three columns can be viewed on a user form. The form works great but because the cells hold information of different lengths it displays the information all unaligned as below: h1&" "h2&" "h3 $14 blah blah etcetc $142 blah blah etcetc $1433 blahblah etcetc Is it possible to establish the string lenth for each h instead of trying to make it space so that the information would align? I thank you in advance for any suggestions. --- Message posted from http://www.ExcelForum.com/ |
Concantenate and align info??
depuyus,
What about using a multi column list box instead ? NickHK "depuyus " wrote in message ... I am trying to concantenate information from three columns into one so that the info contained in the three columns can be viewed on a user form. The form works great but because the cells hold information of different lengths it displays the information all unaligned as below: h1&" "h2&" "h3 $14 blah blah etcetc $142 blah blah etcetc $1433 blahblah etcetc Is it possible to establish the string lenth for each h instead of trying to make it space so that the information would align? I thank you in advance for any suggestions. --- Message posted from http://www.ExcelForum.com/ |
Concantenate and align info??
Thank you so much! I really appreciate the help. I love the code.
didnt realize that I could use a multi column list box. I define multiple columns in the range and it only showed the first column so assumed you couldnt. I will check into that. Thank you both -- Message posted from http://www.ExcelForum.com |
All times are GMT +1. The time now is 11:38 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com