VBA to quickly transpose data

mahmed1

Well-known Member
Joined
Mar 28, 2009
Messages
2,240
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hi Guys,

I have data set that i receive daily that comes in this format

1593527146918.png


What i need to do is transpose the data so it looks like this

1593527316344.png


So the Time and data transposed by column for each day

This is taking me forever to do and would really appreciate your help

Thank You
 

Some videos you may like

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)

DanteAmor

Well-known Member
Joined
Dec 3, 2018
Messages
12,618
Office Version
  1. 2007
Platform
  1. Windows
Did you try the macro from post #9?
Or were you able to solve your problem with the query?
 

mahmed1

Well-known Member
Joined
Mar 28, 2009
Messages
2,240
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hi Dante - thank you

I trued both methods and used your VBa version as my colleagues understand how to manipulate That but i do intend to use powerqueryin future...

there was 1 problem i realised afterwards was that columns A to D had merged cells and wouldn’t work so manually i had to unmerge the cella and then all thw blank cells below it filled with the cell above (im sure this could be done in code)

thanks once again
 

alansidman

Well-known Member
Joined
Feb 26, 2007
Messages
6,148
Office Version
  1. 365
Platform
  1. Windows
Thanks for the feedback. If you are interested in learning more about PQ, then I urge you to obtain a copy of the book "M is for (Data) Monkey" by Ken Puls and Miguel Escobar. It is available from MrE homepage (The MrExcel Store - Welcome to The MrExcel Store) or from Amazon.
 

Watch MrExcel Video

Forum statistics

Threads
1,127,247
Messages
5,623,597
Members
415,981
Latest member
Baltwin

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
Top