+ Reply to Thread
Results 1 to 7 of 7

Sort based on values/coordinates

  1. #1
    Registered User
    Join Date
    11-17-2015
    Location
    Philippines
    MS-Off Ver
    2008, 2010
    Posts
    4

    Sort based on values/coordinates

    Hi Experts. I know this forum is best to those want to learn in excel/vba.

    Please help me to solve this problem.
    I need to sort this items by rows and columns based on their x and y coordinates.

    Input Photos:
    The x and y columns are their coordinates.
    \1

    This should be the output without the x and y coordinates
    \1

    Thank you everyone in advance
    Attached Images Attached Images
    Last edited by dotdll; 11-17-2015 at 10:20 PM.

  2. #2
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229

    Re: Sort based on values/coordinates

    You could use the UDF CountIfs
    Put =concatifs($A$2:$A$11,$B$2:$B$11,F$1,$C$2:$C$11,$E2) in F2 and drag down and right

    Please Login or Register  to view this content.
    _
    ...How to Cross-post politely...
    ..Wrap code by selecting the code and clicking the # or read this. Thank you.

  3. #3
    Registered User
    Join Date
    11-17-2015
    Location
    Philippines
    MS-Off Ver
    2008, 2010
    Posts
    4

    Re: Sort based on values/coordinates

    Hi mickerickson,

    it seems that there is no "concatifs" in excel 2010.
    Maybe im just to weak to do this. can you send me your sample?

    Thank you my friend.

  4. #4
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229

    Re: Sort based on values/coordinates

    ConcatIfs is a UDF, not a part of any version of Excel.
    Copy paste the posted code into a normal module and the function will be available to you.

  5. #5
    Registered User
    Join Date
    11-17-2015
    Location
    Philippines
    MS-Off Ver
    2008, 2010
    Posts
    4

    Re: Sort based on values/coordinates

    Got it!!
    My mistake.
    You are so nice, now its working!!

    Additional question, on the output image above the coordinate is hard coded. What if i will remove those?

    Output should look like this
    output_1.JPG

    Thanks a lot.

  6. #6
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229

    Re: Sort based on values/coordinates

    You could use
    =concatifs($A$2:$A$11, $B$2:$B$11, 10*COLUMN(A1), $C$2:$C$11, 10*ROW(A1))

    But this depends on all the values in B and C being multiples of ten, it will not catch any items whose coordinates are intermediate values (e.g. 12)

  7. #7
    Registered User
    Join Date
    11-17-2015
    Location
    Philippines
    MS-Off Ver
    2008, 2010
    Posts
    4

    Re: Sort based on values/coordinates

    I see. may be I should go with your first advised since those coordinates values sometimes not in whole numbers (eg. 22.72, 81.4, etc). I will try to work and get those output to another sheet or workbook.

    Thanks again my friend, you help me alot.

+ 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. [SOLVED] Assigning values based on coordinates
    By juansn in forum Excel General
    Replies: 4
    Last Post: 10-08-2014, 10:00 AM
  2. sort coordinates independently
    By darby1981 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-25-2013, 03:37 PM
  3. Sort based on another sheet values
    By naflas in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-14-2011, 04:32 AM
  4. GPS coordinates based on ZIP code & country
    By snb in forum Tips and Tutorials
    Replies: 0
    Last Post: 01-06-2011, 11:37 AM
  5. How do I sort based upon values in another column?
    By Huuuze in forum Excel General
    Replies: 5
    Last Post: 10-27-2010, 10:54 AM
  6. Use values as coordinates based on another sheet, formula?
    By cristian.ene in forum Excel General
    Replies: 4
    Last Post: 06-08-2009, 04:54 AM
  7. Convert point coordinates -> pixel coordinates
    By Zorro in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-31-2006, 10:30 PM

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