ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Combining Cells (https://www.excelbanter.com/excel-programming/324156-combining-cells.html)

Greg B...

Combining Cells
 
Hi all

I have 2 cell Surname and Firstname and is it possible to write a code to
get both values to combine in 1 cell.

here is an example

A1 Smith

A2 John

then it appears on another worksheet in cell a1 as:

Smith, John

Thanks in advance

Greg



Mike Fogleman

Combining Cells
 
Put this in A1 of Sheet2 to combine A1 & A2 from Sheet1: =Sheet1!A1&",
"&Sheet1!A2

Mike F
"Greg B..." wrote in message
...
Hi all

I have 2 cell Surname and Firstname and is it possible to write a code to
get both values to combine in 1 cell.

here is an example

A1 Smith

A2 John

then it appears on another worksheet in cell a1 as:

Smith, John

Thanks in advance

Greg




Greg B...

Combining Cells
 
Thanks Mike never put the & sign

Greg




All times are GMT +1. The time now is 09:51 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com