+ Reply to Thread
Results 1 to 4 of 4

Import and sort multiple cells

  1. #1
    Registered User
    Join Date
    03-17-2011
    Location
    Pittsburgh, Pennsylvania
    MS-Off Ver
    Excel 2003
    Posts
    25

    Import and sort multiple cells

    Struggled with the heading, here is my situation.
    I have a sheet that pulls employees names from a master employees sheet and places the names in column A
    We input data relevant to each employee in columns B, C, D, and E
    I need to find a way that when the sheet imports the names, the cells in columns B, C, D and E move with the name
    So if Fred is in cell A4 and in cell B4 has information about Fred, the import puts a new name in cell A4 it will move Fred and the relevant adjacent cells down.
    Each day has a different sheet, and is saved as the date it is relevant for, the only sheet that stays the same is the master employees sheet.
    I have it pulling in the names ok, but it messes up the other cells as they stay in place and the names move.

    RDACS snap shot.png
    Last edited by rhodestransit; 12-14-2020 at 07:47 AM.

  2. #2
    Forum Expert Keebellah's Avatar
    Join Date
    01-12-2014
    Location
    The Netherlands
    MS-Off Ver
    Office 2021 (Windows)
    Posts
    7,900

    Re: Import and sort multiple cells

    When sorting a range like this you have to select all the cells when sorting.
    So if you add a new name you first sort the entire table then the rows stay with the corresponding rows.
    If you convert the cell range to an actual table (a ListObject) then the sorting issues are less complicated.
    Google for working with tables and ListObjects. might throw a light on it.
    ---
    Hans
    "IT" Always crosses your path!
    May the (vba) code be with you... if it isn't; start debugging!
    If you like my answer, Click the * below to say thank-you

  3. #3
    Registered User
    Join Date
    03-17-2011
    Location
    Pittsburgh, Pennsylvania
    MS-Off Ver
    Excel 2003
    Posts
    25

    Re: Import and sort multiple cells

    I figured a way to do it, I recorded a macro of the sort process

  4. #4
    Forum Expert Keebellah's Avatar
    Join Date
    01-12-2014
    Location
    The Netherlands
    MS-Off Ver
    Office 2021 (Windows)
    Posts
    7,900

    Re: Import and sort multiple cells

    Good to hear, recording a macro is the best starting point.
    Happy coding

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 4
    Last Post: 07-30-2016, 01:21 AM
  2. Sort multiple cells?
    By skrot311 in forum Excel General
    Replies: 5
    Last Post: 11-12-2015, 07:37 PM
  3. Sort all cells multiple workbooks
    By Stoney1 in forum Excel General
    Replies: 3
    Last Post: 06-14-2015, 07:57 AM
  4. Import multiple URLs and sort table data underneath
    By ZorroMan in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-28-2013, 01:10 PM
  5. [SOLVED] Copy specific cells from multiple workbooks and import them to a master workbook
    By Alby22 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-28-2012, 12:45 PM
  6. Import and sort macro from multiple sources
    By Negative in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-11-2009, 05:00 PM
  7. Multiple Sort a group of cells on same worksheet
    By swieduwi in forum Excel General
    Replies: 5
    Last Post: 11-22-2008, 10:16 AM

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