+ Reply to Thread
Results 1 to 12 of 12

Sort a list in referenced to code

  1. #1
    Registered User
    Join Date
    03-26-2013
    Location
    Canada
    MS-Off Ver
    ms365
    Posts
    79

    Sort a list in referenced to code

    Hi all,

    Hope everyone is having an awesome day. I am trying to autosort (semi-autosort I guess) a list. I have a list of names in column A, in column B I want to put in a 'code/status'. whatever code I place in B would correspond with the name in A and output that name in another column (say E) which is for that particular code/status. i have attached a sample xls to get a better picture of the results. thank you in advance.

    regards,

    SN
    Attached Files Attached Files
    Last edited by snkhan; 09-18-2022 at 10:25 PM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,288

    Re: Sort a list in referenced to code

    Which version of Excel do you have? This is doable with a formula. Do you specifically want VBA?
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    03-26-2013
    Location
    Canada
    MS-Off Ver
    ms365
    Posts
    79

    Re: Sort a list in referenced to code

    hello,

    I have the latest version (V 2208). Yes sure if the formula would work I'll take that. Thank you for your fast reply.

    regards,

    SN

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,288

    Re: Sort a list in referenced to code

    2208 is a release number, not a version - if it's MS365, then please update your profile NOW.

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,288

    Re: Sort a list in referenced to code

    For MS365:

    =FILTER(A2:A10,B2:B10="good")
    =FILTER(A2:A10,B2:B10="bad")
    =FILTER(A2:A10,B2:B10="in progress")
    Attached Files Attached Files

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,288

    Re: Sort a list in referenced to code

    Any questions?

    If that takes care of your original question, please choose Thread Tools from the menu link above and mark this thread as SOLVED.

    Also, if you have not already done so, you may not be aware that you can thank those who have helped you by clicking the small star icon (* Add Reputation) located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of all those who offered help.

    Please update your profile to MS365 NOW. Thanks.

  7. #7
    Registered User
    Join Date
    03-26-2013
    Location
    Canada
    MS-Off Ver
    ms365
    Posts
    79

    Re: Sort a list in referenced to code

    Hello,

    I am getting #SPILL! error if there are multiple matches, please advise.

  8. #8
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,288

    Re: Sort a list in referenced to code

    Did you clear the entire results area first? Did you look at my sample workbook?

    You still have not updated your profile - this is not just me nagging; it's IMPORTANT.

  9. #9
    Registered User
    Join Date
    03-26-2013
    Location
    Canada
    MS-Off Ver
    ms365
    Posts
    79

    Re: Sort a list in referenced to code

    I think VBA would be a better choice

  10. #10
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,288

    Re: Sort a list in referenced to code

    Why?

    Please update your profile (for the fifth time of asking).

  11. #11
    Registered User
    Join Date
    03-26-2013
    Location
    Canada
    MS-Off Ver
    ms365
    Posts
    79

    Re: Sort a list in referenced to code

    Hello,

    Thank you Thank you Thank you, It's working perfectly now, what I did was paste the filter formula in 'ALL' cells that's why I was getting the error.
    I have updated my profile. thank you again. have an awesome one

    regards,

    SN

  12. #12
    Registered User
    Join Date
    03-26-2013
    Location
    Canada
    MS-Off Ver
    ms365
    Posts
    79

    Re: Sort a list in referenced to code

    Just one last thing if I leave the code blank the output cell shows #CALC! error is there a way to get rid of it, so if there isn't a code attached it just shows a blank cell, not the #CALC! msg? can I use an IFERROR function in someway here?
    thanks again
    Last edited by snkhan; 09-18-2022 at 10:36 PM.

+ 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. Sort cells that are referenced
    By BillyD21 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 12-05-2019, 11:22 PM
  2. [SOLVED] VBA Code to Sort a list with column header activating the code
    By Bobbbo in forum Excel Programming / VBA / Macros
    Replies: 19
    Last Post: 11-04-2019, 05:19 PM
  3. Big List Sort. Not Enough Memory. Help Run my Code. Or help fix or change code Please :)
    By Doc.AElstein in forum Excel Programming / VBA / Macros
    Replies: 47
    Last Post: 06-08-2017, 06:56 AM
  4. [SOLVED] VB Code to sort the list
    By rizmomin in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-18-2016, 08:34 PM
  5. [SOLVED] sort referenced array
    By sick stigma in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-26-2015, 04:58 PM
  6. [SOLVED] VBA to Custom Sort Data Based on Referenced List
    By Kehoth01 in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 02-21-2014, 05:51 PM
  7. [SOLVED] Sort referenced sheets together!
    By Addy in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-12-2006, 10:50 AM

Tags for this Thread

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