How to concanate 2 col in single col?

VBABEGINER

Well-known Member
Joined
Jun 15, 2011
Messages
1,284
Office Version
  1. 365
Platform
  1. Windows
I have data in Col AG 13 and AI 13.
I want to concatenate this data in COL O.
Experts, How do i do this?
This is in the case of two column.
How can concanate done for 3 or 4 columns?
Masters help required?
 

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)
Maybe like this

Code:
Sub concat()
Dim LR As Long, i As Long
LR = Range("AG" & Rows.Count).End(xlUp).Row
For i = 2 To LR
    Range("O" & i).Value = Range("AG" & i).Value & Range("AI" & i).Value
Next i
End Sub
 
Upvote 0
:beerchug:


I wanted to say something about MrExcel.
I didn’t understand your brain. God has manufactured special kind brain items, that is You guys “MrExcel”.
You guys are really Awsome….and your knowledge is Excellent!!
Cheers!!


:pray:
 
Upvote 0
one query still left guys.

how can be done concatenate for 3 col or 4 col?
 
Upvote 0
Just add in more ranges

Code:
Sub concat()
Dim LR As Long, i As Long
LR = Range("AG" & Rows.Count).End(xlUp).Row
For i = 2 To LR
    Range("O" & i).Value = Range("AG" & i).Value & Range("AI" & i).Value & Range("BA" & i).Value
Next i
End Sub
 
Upvote 0

Forum statistics

Threads
1,224,518
Messages
6,179,253
Members
452,900
Latest member
LisaGo

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top