LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
Rob Rob is offline
external usenet poster
 
Posts: 718
Default Dynamically refreshing Pivot Table Range.

I have a Pivot Table which is populated by a worksheet which itself is
populated via a SQL Server Stored Proc, using OLE DB. I get the RowCount of
the worksheet that has the data read into it, and use it for the Upper Row
limit of the Pivot Table Range, using the following code:

Sheets("Projected Shipments").PivotTableWizard SourceType:=xlDatabase,
SourceData:= _
"Sheet1!R1C1:R" & dRowCount & "C29"

Where dRowCount is my 'dynamic' number of rows returned by the SQL
Statement. The problem is after my processes run, the Upper range for the
Pivot table data is not the dynamic value I supply above.

How can I get it so that I can dynamically and correctly reset the
boundaries (rows) for the PivotTable cache to get it to include all of my
rows?

Thank you
 
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
Refreshing a pivot table Neville Bailey[_2_] Excel Discussion (Misc queries) 1 November 16th 08 05:47 PM
Pivot table refreshing Daniel Excel Discussion (Misc queries) 5 July 12th 07 05:02 PM
When refreshing pivot tables my pivot table chart type changes hannah220507 Excel Discussion (Misc queries) 1 May 22nd 07 02:57 PM
Refreshing a Pivot Table from a dynamic range matpj[_4_] Excel Programming 2 October 20th 05 03:19 PM
OfficeXP "Cannot open pivot table source file" when refreshing pivot table Luc Alquier Excel Programming 2 December 9th 03 11:11 PM


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

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

About Us

"It's about Microsoft Excel"