Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
![]()
On Sat, 19 Jul 2008 09:19:00 -0700, NES wrote:
Please tell me that someone has managed to develop a macro for sorting a list of names by [Last Name] then by [First name] when the names include a mix of 2, or 3, or 4 words. I've tried setting them in to tables and doing manipulations there, but have failed to find an efficient way of doing it. I would be most grateful for any help on this that you may give. Thanks. Here's a trick for you. It takes a bit of work to set up, but it shouldn't affect other uses of the list. The names don't have to be in a table to do this. Replace the spaces between words in the same part of each name with nonbreaking spaces (Ctrl+Shift+spacebar), leaving a regular space only between the full "first (and middle) name" and the full "last name". You have to do this manually because Word has no understanding about which of the middle words belong to "first name" and which belong to "last name". (Most people aren't sure!) Here are some examples, using "nbsp" to represent a nonbreaking space: GeorgenbspWashington Carver Ludwig vannbspBeethoven MartinnbspLuther KingnbspJr. Anton vannbspdernbspHuysen In the Sort dialog, click the Options button, choose the Other option, and replace the contents of the box with a space character (a regular space, not a nonbreaking one). Click OK. Back in the Sort dialog, tell it to sort by Word 2 and then by Word 1. (These choices appear in the dropdowns only after you've set the options.) Click OK, and it should all be done. -- Regards, Jay Freedman Microsoft Word MVP FAQ: http://word.mvps.org Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit. |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
sorting | Mailmerge | |||
sorting | Microsoft Word Help | |||
sorting by last name | Microsoft Word Help | |||
sorting by last name | Mailmerge | |||
Sorting | Microsoft Word Help |