bpc21


In Excel 2003, I have two columns of information (intersection street names) Oak and Main for example. I would like to combine the information into one cell seperated by an ampersand (Main & Oak). I need to alphabetize the street names upon concatenation so that Main always lists before Oak. Suggestions Any advice is appreciated.

BPC




Re: Alphabetize upon concatenate

magicalclick


Try this if you want formulat

=IF(A1<B1, A1 & " & " & B1,B1 & " & " &A1 )

and fill it for the whole column

Basically the code is like (not real code) if you do it in macro.

loop

if cellA.value < cellB.value then

cellC.value = cellA.value + " & " + cellB.value

else

cellC.value = cellB.value + " & " + cellA.value

end if

loop end