Consolidating data to a single mastersheet VBA (importing, transposing questions)

Ming Sheng

New Member
Joined
Apr 7, 2019
Messages
1
How do I set up a central file in which every morning you can import and analyze the data in those 24 hourly summary files rather than doing this manually (copying/pasting from those 24 files each day).

I have to import the data to row-wise, should i select range using importbox or, sorry I am new to VBA.

Converting these from multiple files
[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Time[/TD]
[TD]3:00[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Temperature[/TD]
[TD]37[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]pH[/TD]
[TD]5.47[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]dO2[/TD]
[TD]52.3[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

To this

[TABLE="width: 500"]
<tbody>[TR]
[TD]Time[/TD]
[TD]Temperature[/TD]
[TD]pH[/TD]
[TD]dO2[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]0:00[/TD]
[TD]37[/TD]
[TD]5.47[/TD]
[TD]52.3[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1:00[/TD]
[TD]37[/TD]
[TD]5.8[/TD]
[TD]53.3[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]2:00[/TD]
[TD]36.8[/TD]
[TD]5.9[/TD]
[TD]54.1[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3:00[/TD]
[TD]36.5[/TD]
[TD]5.4[/TD]
[TD]53.3[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]4:00[/TD]
[TD]37[/TD]
[TD]5.9[/TD]
[TD]52.3[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]5:00[/TD]
[TD]37[/TD]
[TD]5.9[/TD]
[TD]50.3[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]6:00[/TD]
[TD]37[/TD]
[TD]5.9[/TD]
[TD]49.2[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]~[/TD]
[TD]~[/TD]
[TD]~[/TD]
[TD]~[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]~[/TD]
[TD]~[/TD]
[TD]~[/TD]
[TD]~[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]~[/TD]
[TD]~[/TD]
[TD]~[/TD]
[TD]~[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.
We would need a little more information to help. What is the full path to the folder containing the files? What is the file extension (xlsx, xlsm)? Are these the only files in that folder? What is the name of the sheet containing the data in each file? Is the data in columns A and B? What is the name of the sheet in the central file where you want to consolidate the data? Do you want the data of each day to be appended to the data of the previous days or do you want just the data for one day to appear in the central file?
 
Upvote 0

Forum statistics

Threads
1,223,904
Messages
6,175,295
Members
452,632
Latest member
jladair

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