Combining Data Cells

  • Thread starter Thread starter Q
  • Start date Start date
Q

Q

hi
i have the following lines of code:

'Copy the first name to A31
Range("H" & i).Copy Destination:=Sheets
("Template").Range("A31")
'Copy the last name to cell B31
Range("I" & i).Copy Destination:=Sheets
("Template").Range("B31")

and the output comes out like: Rick Johnson
i need a way to combine the first name and last name
together so the last name comes right after the first
name, with an output like: Rick Johnson

i know you can use bookmarks to achieve this is word, is
there a way to achieve this in excel without resizing the
columns because obviously the first names range in the
number of letters. ok, i hope i didn't confuse anyone,
thanks in advance. if you need anymore clarification just
email me. thanks again

~q
 
Hi
try
Worksheets("Template").Range("A31").value = _
Range("H" & i).value & " " & Range("I" & i).value

no need for copy+paste
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top