+ Reply to Thread
Results 1 to 5 of 5

Arrange columns into set order

  1. #1
    Registered User
    Join Date
    04-15-2011
    Location
    Fordoun, Scotland
    MS-Off Ver
    Excel 2003
    Posts
    11

    Smile Arrange columns into set order

    Hi Again

    I am trying to arrange columns of data into a set coulumn layout from various files that have the same column headers but are in all differing order of layout.

    I have attached 2 samples of differing column arrangements and a sample of what the final column arrangement layout shoud be.

    I have tried looking for the column header which is the same in each file but when I find it I do not know how to select the complete column..............

    Any help on this would be appreciated.

    Regards

    Stan
    Attached Files Attached Files
    Last edited by stawil; 06-16-2011 at 09:07 AM.

  2. #2
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Arrange columns into set order

    hi, stawil, please check files, run code "test". The code is the same in both of them. In order to use it in different files you will need to put it to personal workbook.
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    04-15-2011
    Location
    Fordoun, Scotland
    MS-Off Ver
    Excel 2003
    Posts
    11

    Re: Arrange columns into set order

    Hi Watersev

    I ran the script and it sorted the columns in both samples, but not into the correct order as per the Sample Final Layout..........

    Could you talk through the code ( I am new to VBA at this level) and I will see if I can re-arange what you have been very kind in writing for me. If I can understand what it is doing I may be able to apply the correct column order.

    Many Thanks

    Stan

  4. #4
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Arrange columns into set order

    please check attachment, missed one setting
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    04-15-2011
    Location
    Fordoun, Scotland
    MS-Off Ver
    Excel 2003
    Posts
    11

    Smile Re: Arrange columns into set order

    Hi Watersev

    Works a treat, don't understand how, but brilliant............

    Many thanks, you guys are great........

    Regards

    stawil

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1