Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Custom Sort a Pivot Table (possibly w/ VBA?)

This is my challenge:

I have a pivot table that has revenue data by vendor (see example
below).

Vendor Revenue
ABC $124
DCE $321
OTHERS $100
FGH $20
XXX $10




I need to sort the data by descening revenue with one exception - I
would like to have vendor "Others" show up at the bottom of the pivot
table (see desired result below). I can do this manual by sorting it
and the dragging field "Others" to the bottom, or right clicking it
and selecting Sort-Move to End.

Vendor Revenue
DCE $321
ABC $124
FGH $20
XXX $10
OTHERS $100




Is there a macro I can create to do this? I tried using a Custom List
and/or a calculated field for this but I could not get the desired
result.

The number of vendors varies by country so the size of the pivot table
is not fixed.

If you need additional information, please let me know.

Thanks,

Nik
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,560
Default Custom Sort a Pivot Table (possibly w/ VBA?)

Copy your Pivot table out and paste it somewhere, give it header labels, then
get rid of any totals you have. You can now sort it. Unless you want to give
it a special sort order, you will have to move "Other" manually

" wrote:

This is my challenge:

I have a pivot table that has revenue data by vendor (see example
below).

Vendor Revenue
ABC $124
DCE $321
OTHERS $100
FGH $20
XXX $10




I need to sort the data by descening revenue with one exception - I
would like to have vendor "Others" show up at the bottom of the pivot
table (see desired result below). I can do this manual by sorting it
and the dragging field "Others" to the bottom, or right clicking it
and selecting Sort-Move to End.

Vendor Revenue
DCE $321
ABC $124
FGH $20
XXX $10
OTHERS $100




Is there a macro I can create to do this? I tried using a Custom List
and/or a calculated field for this but I could not get the desired
result.

The number of vendors varies by country so the size of the pivot table
is not fixed.

If you need additional information, please let me know.

Thanks,

Nik

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Custom Sort a Pivot Table (possibly w/ VBA?)

On Feb 16, 10:40*am, David wrote:
Copy your Pivot table out and paste it somewhere, give it header labels, then
get rid of any totals you have. You can now sort it. Unless you want to give
it a special sort order, you will have to move "Other" manually



" wrote:
This is my challenge:


I have a pivot table that has revenue data by vendor (see example
below).


Vendor * * Revenue
ABC * * * * $124
DCE * * * * $321
OTHERS * *$100
FGH * * * * $20
XXX * * * * *$10


*I need to sort the data by descening revenue with one exception - I
would like to have vendor "Others" show up at the bottom of the pivot
table (see desired result below). I can do this manual by sorting it
and the dragging field "Others" to the bottom, or right clicking it
and selecting Sort-Move to End.


Vendor * * Revenue
DCE * * * * $321
ABC * * * * $124
FGH * * * * $20
XXX * * * * *$10
OTHERS * *$100


Is there a macro I can create to do this? I tried using a Custom List
and/or a calculated field for this but I could not get the desired
result.


The number of vendors varies by country so the size of the pivot table
is not fixed.


If you need additional information, please let me know.


Thanks,


Nik- Hide quoted text -


- Show quoted text -


Thanks. I was trying to avoid doing this manual. I did try recording a
macro but I was stuck on the "position= XX" part which moves the field
to the end and depends on the actual number position (bottom, end,
last didn't work).
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
Manual sort in a pivot chart/pivot table Isabel Charts and Charting in Excel 4 November 5th 09 02:48 PM
custom field with custom formula in pivot table! Sedaghat Nejad Excel Worksheet Functions 2 June 21st 09 11:19 AM
top 10, custom, and sort asc./desc. in pivot table Sue Excel Discussion (Misc queries) 1 February 28th 08 09:34 PM
How do I sort pivot table data outside a pivot table Michael Excel Worksheet Functions 1 January 4th 07 02:45 PM
pivot table sort entries that don't yet appear in table rachael Excel Discussion (Misc queries) 11 September 19th 05 11:29 PM


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

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"