merge multiples excel files data quickly

majidsiddique

Board Regular
Joined
Oct 22, 2018
Messages
164
Hi All,

can i quickly merge multiple excel files Data in single file? Heading should be same or different?

Thanks.
Majid
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Sheet1 DATA
[TABLE="width: 817"]
<colgroup><col><col><col><col><col><col><col></colgroup><tbody>[TR]
[TD]S.NO[/TD]
[TD]Catogery Item[/TD]
[TD]CAT #[/TD]
[TD]PRODUCT[/TD]
[TD]QTY-22-10-18[/TD]
[TD]RATE[/TD]
[TD]TOTAL[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Vascular[/TD]
[TD]MD-061102A00[/TD]
[TD] INTRODUCER SHEATH 6F[/TD]
[TD]232[/TD]
[TD]781.77[/TD]
[TD]181370.64[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]Vascular[/TD]
[TD]MD-071102A00[/TD]
[TD] INTRODUCER SHEATH 7F[/TD]
[TD]39[/TD]
[TD]794.31[/TD]
[TD]30978.09[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]Vascular[/TD]
[TD]MD-081102A00[/TD]
[TD] INTRODUCER SHEATH 8F[/TD]
[TD]200[/TD]
[TD]765.37[/TD]
[TD]153074[/TD]
[/TR]
</tbody>[/TABLE]


Sheet2 DATA

[TABLE="width: 891"]
<colgroup><col><col span="2"><col><col><col><col></colgroup><tbody>[TR]
[TD]S.NO[/TD]
[TD]Catogery Item[/TD]
[TD]CAT #[/TD]
[TD]PRODUCT[/TD]
[TD]QTY-22-10-18[/TD]
[TD]RATE[/TD]
[TD]TOTAL[/TD]
[/TR]
[TR]
[TD="align: right"]1[/TD]
[TD]CRHF[/TD]
[TD]04122JM[/TD]
[TD]CATH.TORQR 5FR RENEAWAL(04122JM)[/TD]
[TD]5[/TD]
[TD]19621.35[/TD]
[TD]98106.75[/TD]
[/TR]
[TR]
[TD="align: right"]2[/TD]
[TD]CRHF[/TD]
[TD]04402SM[/TD]
[TD]CATH STABLE MAPR CE[/TD]
[TD]1[/TD]
[TD]110000[/TD]
[TD]110000[/TD]
[/TR]
[TR]
[TD="align: right"]3[/TD]
[TD]CRHF[/TD]
[TD]053280000[/TD]
[TD]CABLE EGM SAFETY 8[/TD]
[TD]1[/TD]
[TD]16538.23[/TD]
[TD]16538.23
[/TD]
[/TR]
</tbody>[/TABLE]

is it possible in excel to merge in sheet3 paste sheet1 data then paste sheet2 data where sheet1 data row end start with next row to sheet 2 data?
 
Upvote 0
Not sure how you define fast. But try this:
Your posting said:
merge multiples excel files data quickly

But then you said sheets.

This script copies data from sheets 1 and 2 to sheet 3
These are sheets not files.
Code:
Sub Copy_One_And_Two_To_Three()
'Modified  11/7/2018  6:06:50 AM  EST
Application.ScreenUpdating = False
Dim Lastrow As Long
Dim Lastrowb As Long
Dim Lastrowbc As Long
Dim Lastrowbc As Long
Lastrow = Sheets(1).Cells(Rows.Count, "A").End(xlUp).Row
Lastrowb = Sheets(2).Cells(Rows.Count, "A").End(xlUp).Row
Sheets(1).Rows(1).Resize(Lastrow).Copy Sheets(3).Rows(1)
Lastrowc = Sheets(3).Cells(Rows.Count, "A").End(xlUp).Row + 1
Sheets(2).Rows(1).Resize(Lastrowb).Copy Sheets(3).Rows(Lastrowc)
Application.ScreenUpdating = True
End Sub
 
Last edited:
Upvote 0
hi,

i apply this, but there is an error on run time on sheet 3.

Sub Copy_One_And_Two_To_Three()
'Modified 11/7/2018 6:06:50 AM EST
Application.ScreenUpdating = False
Dim Lastrow As Long
Dim Lastrowb As Long
Dim Lastrowbc As Long
Dim Lastrowbc As Long
Lastrow = Sheets(1).Cells(Rows.Count, "A").End(xlUp).Row
Lastrowb = Sheets(2).Cells(Rows.Count, "A").End(xlUp).Row
Sheets(1).Rows(1).Resize(Lastrow).Copy Sheets(3).Rows(1)
Lastrowc = Sheets(3).Cells(Rows.Count, "A").End(xlUp).Row + 1
Sheets(2).Rows(1).Resize(Lastrowb).Copy Sheets(3).Rows(Lastrowc)
Application.ScreenUpdating = True
End Sub

duplicate deceleration in current scope.
 
Upvote 0
Sorry:
Try this:
Code:
Sub Copy_One_And_Two_To_Three()
'Modified  11/7/2018  7:02:13 AM  EST
Application.ScreenUpdating = False
Dim Lastrow As Long
Dim Lastrowb As Long
Dim Lastrowc As Long
Lastrow = Sheets(1).Cells(Rows.Count, "A").End(xlUp).Row
Lastrowb = Sheets(2).Cells(Rows.Count, "A").End(xlUp).Row
Sheets(1).Rows(1).Resize(Lastrow).Copy Sheets(3).Rows(1)
Lastrowc = Sheets(3).Cells(Rows.Count, "A").End(xlUp).Row + 1
Sheets(2).Rows(1).Resize(Lastrowb).Copy Sheets(3).Rows(Lastrowc)
Application.ScreenUpdating = True
End Sub
 
Upvote 0
thanks a lot sir,

its working properly. kindly tell me merge multiples excel files data quickly which was actual question.

Majid,
 
Upvote 0
Glad I was able to help you.
Come back here to Mr. Excel next time you need additional assistance.
 
Upvote 0
I thought I answered your question.
Is this a new question?

You need to explain more.
 
Upvote 0
if the same DATA will be on different excel files (Vas1 and CRHF2 ) two files then how i can merge it in combine both data in new excel file?
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,289
Members
452,631
Latest member
a_potato

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