Concatenate and format

A

Adam

Concatenate and format

Hey there.
Have a large spreadsheet of stock transactions.
Currently have a column for number of shares and another
column for symbol.
I want to concatenate into one cell and keep the share
amount right justified and the description left justified.

Old

1000 CSCO
50 XLNX

These are in separate columns

But when I concatenate I get

1000 CSCO
50 XLNX

How can I get the info in one cell and nicely formatted?

Thanks
Adam
 
B

Bob Phillips

Adam,

Main problem is that most fonts will invalidate anything you do, as some
characters will display wider than others. So, if you had a formula like
=A1&LEFT(" ",6-LEN(A1))&B1
you will end up with a consistent number of characters, but it still won't
line up. Combine it with a proportional font like Courier, and you may get
what you want.
 
B

Bernard V Liengme

Hi Adam,
With the number of shares in A1, the symbol in B1, try either of these:
=TEXT(A1,"????")&" "&B1
=TEXT(A1,"####")&" "&B1

Bernard
 
Top