• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Change data in rows to columns, variable rows

sophie giesen

New Member
Hi

I have been provided with a text file with data groups that I need to validate. The data groups are made of several types of data but each group contains a different number of data items and data types eg name, date & time may be one group but name, time, room & supervisor may be another group. The problem is that when I copy it into excel, it copies all of the data groups into a single column. The data groups are separated by a blank row. An example is below.
name
date
time
(Blank row)
name
time
room
supervisor
(blank row)
name
room
supervisor
(blank row)

There are nearly 5000 rows so I can't separate the data manually but I need a way to change the data to spread across columns as per below:

name date time
Name time room supervisor
name room supervisor

Given there is a blank row between each group I think this should provide a consistent group separator but I don't know how to write the macro to recognise this and transpose each group. Apologies, I haven't used macros in a long time and can use any help you can provide :)
 
Back
Top