Alphabetizing a list in Pages

Discussion in 'Mac Apps and Mac App Store' started by stenoboy, Apr 13, 2008.

  1. macrumors newbie

    Nov 18, 2007
    Does anyone know how to alphabetize a list in Pages? I can't find anything in the help menus or online. Each separate item on the list is a new line, so I don't know if it's a paragraph style I need?
  2. macrumors newbie

    Mar 10, 2009
    How to alphabetize in pages!

    If you wish to alphabetize a list in pages....

    1. Make the list as below say it's names -


    2. Insert a table on the page

    3. Highlight the list of names and drag them into a box in the table - they should automatically each end up in their own box.

    4. Go to the 'edit tool bar' and click on the table logo at the top, bringing up all the table edit options.

    5. Select only one box in the table ie. the one at the top of the list.
    Go to "Edit Rows & Columns" there is a drop down menu. This menu will allow you to 'sort ascending' 'sort descending' etc. Select which you would like.

    6. Once the contents of the table are in the order you want, move the text out of the table and get rid of the table.
  3. macrumors newbie

    Mar 24, 2010
    Have no luck moving out of the table, back to regular text

    I have no luck selecting the contents of a table and moving it back to regular text. I can't believe Apple makes no easy way to just write a grocery list and select all, sort asend or desend. So every time you want to add to a list, you have to move the list into and out of a table? I'm shocked. So once I have the list asended or desended, I have tried selecting the table, coping it and , but all I get is another table, not the raw contents of the boxes.
  4. macrumors 65816


    Jul 17, 2008
    You also could do this, if you've run AppleScript utility and have the AS menu in the menu bar.

    Open your script editor and paste this file:

    tell application "Pages"
    	-- not a perfect solution, but a near-perfect one
    	-- code stolen liberally from:
    	set blob to the selection of document 1
    	set blobY to paragraphs of text of blob
    	set TID to AppleScript's text item delimiters
    	set AppleScript's text item delimiters to {ASCII character 10}
    	set blobList to (blobY as string)
    	set AppleScript's text item delimiters to TID
    	set blobReplace to do shell script "echo " & quoted form of blobList & " | sort -f"
    	set the selection of document 1 to blobReplace
    end tell
    The script should be saved in this folder: /Users/<user name>/Library/Scripts/Applications/Pages/

    Now it will appear in the AppleScript menu, under "Pages Scripts"

  5. macrumors 65816


    Jul 17, 2008
    Even better way ...

    Open System Preferences
    Open Keyboard
    Select Keyboard Shortcuts tab
    Select Services in left-hand pane
    Scroll down to Text entry.

    You'll see Sort Lines Ascending and Sort Lines Descending

  6. macrumors newbie

    Aug 2, 2006
    I must be really blind...... I don't see this option..... *shrug*
  7. macrumors 603

    Oct 22, 2007
    An Island in the Salish Sea
    Must be a Snow Leopard thing, I don't see it either. I'm at 10.5.8 ...

    If I need an alphabetized list in Pages I do the Table Thing, but if I think I'll be needing to edit it, I keep the table but make all the lines invisible. Then you can add some rows and names, and re-sort whenever needed.
  8. macrumors 6502a

    Jan 9, 2007
    Covington/Lake Morton, WA, USA
    Pages can only sort in a table. Install WordService from Devon Technologies to add sorting in the main text layer of a word processing document.
  9. macrumors 603

    Oct 22, 2007
    An Island in the Salish Sea
    Thanks PeggyD. Just tried it and it seems to work well. A couple of other interesting things have also been installed into the Services menu... looking forward to trying those too.

    Thanks again.
  10. macrumors member

    Sep 21, 2007
    Ask the Goverment!
    Works in Numbers too... Sort Ascending is magic!
  11. macrumors newbie

    Oct 26, 2010

    This script worked very well to sort the text, but the problem, as with WordServices, is that it doesn't keep any of the formatting, which is frustrating for a long bibliography in which certain things need to be italicised. I confess I know nothing about writing scripts, but is it possible in anyway to make it sort and keep those style features?
  12. SVHarmony, Nov 13, 2010
    Last edited: Nov 13, 2010

    macrumors newbie

    Aug 25, 2010
    Pacific Northwest
    I think I have it...

    Needing to find a way to alphabetize a list I had made in Pages, I first, of coarse, looked here in MacForums. Not finding what I wanted I proceeded to alphabetize the list the old fashion way. After I finished I decided I needed another column and clicked on the top of one of the columns. I'm not sure what this is called ... it was labeled according to each row: A,B, and C. (I only had the three columns to start with) Upon right clicking 'C' I saw that sure enough it gave me options of "sort ascending, sort descending". I could have clicked any of the rows and it would have given me the option of "sort ascending, sort descending". I hope I understood the question correctly.
    Hope this helps someone else.
    Now I hope I can remember this when I need it once again *wink.
  13. macrumors newbie

    Jan 3, 2010
    Installing WordService from Devon Technologies solved problem for me :)

    Installing WordService from Devon Technologies solved this problem for me, had been bugging me for a while as I have just stopped using Word.

    If you install after reading the 'read me' file first which tells you how to install and then follow these steps below it is easy to add a sort ascending, sort descending service to pages:

    1. Open System Preferences
    2. Open Keyboard
    3. Select Keyboard Shortcuts tab
    4. Select Services in left-hand pane
    5. Scroll down to Text entry
    6. You'll see Sort Lines Ascending and Sort Lines Descending - Tick boxes
    7. DONE
  14. macrumors newbie

    Sep 28, 2011
    The Easy Way (I guess...)

    >highlight text/list
    >Format>Table>Convert Text to Table
    >Inspector>Table Tab>Edit Rows and Columns>Sort Ascending/Descending
    >Format>Table> Convert Table to Text

    Hope it helps! :)
  15. macrumors newbie

    Jan 24, 2012
    helpful site

    A favorite site of mine for various list sorting and list refinements is

    I just used it to sort my Pages list using cut and paste.
  16. macrumors newbie

    Jan 2, 2013
    Thanks so much, so simple once you explained it :)

Share This Page