Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 138
Default Sorting by line when multiple lines correspond to it?

Hi all,

I am working on creating a contact list and I want to be able to sort by
client name, however, there are several lines for each client name, so when I
sort by client name currently, the first line will come up fine, but then the
rest of the associated lines will all get grouped together as being "blank."
Is there any way to sort without writing the client name on each line?
Please see below. I would like all the info for client A, B, C, etc. to move
when I sort rather than just the top line.

Thanks!

Client Phone Email
A 654654 weffwefwe
654654 werw
22477 545487
323211 57778768
B 3.21132E+15 6354654
4564 5887687
C asdf asdf
sadf afds
asfd weffwefwe
asdf afds
D f asdf
E wef sdaf
sd a
d sdaf
s df
F s sdaf

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Sorting by line when multiple lines correspond to it?

Use a helper column (eg column D) - this will only be used temporarily
and can be deleted afterwards. In D2 you can enter this formula:

=IF(A2="",A1+0.01,INT(A1)+1)

Copy this down column D to cover all your data - it will give you a
number incremented by 0.01 for each name, and thus will allow up to
100 entries under each name. Fix the values in column D by
highlighting the column, click <copy then Edit | Paste Special |
Values | OK | <Esc.

Now you can sort the data using the helper column, to retain the sub-
rows under the main row.

Hope this helps.

Pete


On Feb 4, 4:55*pm, Jonathan
wrote:
Hi all,

I am working on creating a contact list and I want to be able to sort by
client name, however, there are several lines for each client name, so when I
sort by client name currently, the first line will come up fine, but then the
rest of the associated lines will all get grouped together as being "blank.." *
Is there any way to sort without writing the client name on each line? *
Please see below. *I would like all the info for client A, B, C, etc. to move
when I sort rather than just the top line.

Thanks!

Client *Phone * Email
A * * * 654654 *weffwefwe
* * * * 654654 *werw
* * * * 22477 * 545487
* * * * 323211 *57778768
B * * * 3.21132E+15 * * 6354654
* * * * 4564 * *5887687
C * * * asdf * *asdf
* * * * sadf * *afds
* * * * asfd * *weffwefwe
* * * * asdf * *afds
D * * * f * * * asdf
E * * * wef * * sdaf
* * * * sd * * *a
* * * * d * * * sdaf
* * * * s * * * df
F * * * s * * * sdaf


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,290
Default Sorting by line when multiple lines correspond to it?

Another way...
Use John Walkenbach's tip here...
http://j-walk.com/ss/excel/usertips/tip040.htm
Except between steps 5 and 6 (while the "blank" cells are still selected);
Format the cells with a custom number format of ";;;" - (three semi-colons).
Then continue with step 6.
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware
(Excel Add-ins / Excel Programming)



"Jonathan" <
wrote in message
Hi all,
I am working on creating a contact list and I want to be able to sort by
client name, however, there are several lines for each client name, so when I
sort by client name currently, the first line will come up fine, but then the
rest of the associated lines will all get grouped together as being "blank."
Is there any way to sort without writing the client name on each line?
Please see below. I would like all the info for client A, B, C, etc. to move
when I sort rather than just the top line.
Thanks!

Client Phone Email
A 654654 weffwefwe
654654 werw
22477 545487
323211 57778768
B 3.21132E+15 6354654
4564 5887687
C asdf asdf
sadf afds
asfd weffwefwe
asdf afds
D f asdf
E wef sdaf
sd a
d sdaf
s df
F s sdaf

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Sorting by line when multiple lines correspond to it?

Make your life easier by adding the client names in the blank spaces.

Select Client column and F5SpecialBlanksOK

Type = sign in active blank cell then hit CTRL + ENTER.

Copy that column and paste special(in place)valuesokesc


Gord Dibben MS Excel MVP

On Mon, 4 Feb 2008 08:55:00 -0800, Jonathan
wrote:

Hi all,

I am working on creating a contact list and I want to be able to sort by
client name, however, there are several lines for each client name, so when I
sort by client name currently, the first line will come up fine, but then the
rest of the associated lines will all get grouped together as being "blank."
Is there any way to sort without writing the client name on each line?
Please see below. I would like all the info for client A, B, C, etc. to move
when I sort rather than just the top line.

Thanks!

Client Phone Email
A 654654 weffwefwe
654654 werw
22477 545487
323211 57778768
B 3.21132E+15 6354654
4564 5887687
C asdf asdf
sadf afds
asfd weffwefwe
asdf afds
D f asdf
E wef sdaf
sd a
d sdaf
s df
F s sdaf


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do make a line correspond to date soconfused Charts and Charting in Excel 7 May 24th 07 08:34 PM
Looking for code to separate one line of text into multiple lines in Excel [email protected] Excel Worksheet Functions 1 February 13th 07 12:59 AM
display 1 line of multiple worksheets into multiple lines on 1 wks Golf Nut Excel Worksheet Functions 1 October 5th 06 08:28 AM
Break cell into multiple lines by line break Chia Excel Discussion (Misc queries) 1 August 20th 06 06:37 AM
How do I group multiple lines of excel info for easy sorting ericsayang New Users to Excel 2 January 12th 06 08:06 PM


All times are GMT +1. The time now is 10:10 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"