VSTO 2005: How to prevent Excel from Autosorting Pivot table RRS feed

  • Question

  • Hi,

    I am using VSTO 2005. I have created a pivot table. But Excel automatically sorts the data. But I want the data unsorted as it is. How do I prevent the auto sorting. Can anybody please help me?


    Monday, April 30, 2012 2:00 PM


  • Hi SandyXYZ,

    Welcome to the MSDN forum!

    In excel, there are no options available to turn this automatic sorting off or to perform a custom sort on your PivotTable data. To prevent a PivotTable from being sorted, you can create a custom list using the unsorted source data on the worksheet. To custom sort a PivotTable, you can first sort the source data as the way you want it on the worksheet, and then create a custom list using the sorted source data. 

    You can refer to the KB for more details on this issue.


    Yoyo Jiang[MSFT]
    MSDN Community Support | Feedback to us

    • Proposed as answer by Siddharth Rout Thursday, May 3, 2012 7:46 AM
    • Marked as answer by Dummy yoyo Monday, May 7, 2012 5:41 AM
    Thursday, May 3, 2012 6:13 AM