Converting data from one tab to another

RandyD123

Active Member
Joined
Dec 4, 2013
Messages
289
Office Version
  1. 2016
Platform
  1. Windows
I know this is a big "ask", but I need some help. What I need to happen is all the data on the "raw data" sheet needs to be converted to the format on the "converted data" tab.


I can of course do this manually but I was looking to do this with a macro and run it from a button on the "raw data" tab.


This is what will happen:
1. Airline Name and Flight Number will convert to combine both of those columns and the result will be like shown on the "converted data" tab.
2. Equipment Name column will not be needed on the "converted data" tab.
3. The ETD time column will have to convert to just a number/text format.
4. The Day Of Week column will have to sort to the format shown on the "converted data" tab.
5. The conversion must produce the end result to be exactly as shown on the "converted data" tab, or at least as close as possible. Notice that all the info is sorted by day then by airline and then by time.


Any help would be much appreceiated. Thank you.....


https://1drv.ms/x/s!Ai35lp1419xzo4R8dmsgD0gET7HAsA
 
I think you may have misread that...."RESULTS" of the conversion, not "rest" of the conversion!!! SEE POST #9
 
Last edited:
Upvote 0

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
So i have found a workaround for the naming of the airlines properly, not the best workaround but it works. But post #6 are the 2 concerns if solvable that would be awesome. Thanks for all the help so far!!!
 
Upvote 0
Does the output need to be sorted alphabetically by airline code or is there some other sort order?
 
Upvote 0
The sort order should be by Airline then by time. So AA would come first with all the flights listed by time, earliest first. See below. Also in the file that I uploaded there is an example of the layout on the "converted data11" tab.

AA1729PHL60099
AA4405DCA61080
AA5474CLT61579
AA3294ORD72067
AA4825PHL80350
AA5675CLT80379
AA4923PHL105050
AA4434DCA122080
AA5632CLT124579
AA4792PHL124750
AA3291ORD155667
AA5595CLT170079
AA4841PHL170150
AA5061DCA172067
AA1904PHL183099
DL2179ATL600149
DL3449LGA60050
DL6182DTW70076
DL6193DTW123565
DL6205DTW164565
SW4110MDW605143
SW4104BWI610143

<tbody>
</tbody>
 
Last edited:
Upvote 0
In this version of the file: https://1drv.ms/x/s!Ai35lp1419xzo4UDEX6nexi5KPJGYg you can see my workaround for renaming the airlines. Also notice the the "desired output" tab. When the script is run it creates a new tab called "sheet1". At this point it's only the sort order that needs a bit of tweaking. Not sure if there is a cleaner way to rename the airlines so they get renamed AA, DL, SW, UA.... Again, thank you for all the help on this one!!!
 
Upvote 0

Forum statistics

Threads
1,215,326
Messages
6,124,270
Members
449,149
Latest member
mwdbActuary

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