Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default When to Stop

I have a macro that updates two pivot tables that are side
by side. Next to the tables is a calculated field based
on the two tables. Once the tables have been updated the
column with the calculated field needs to have the
calculation copied down to the bottom of the now longer
pivot tables.

Is there anyway to automate this? I need the copying to
stop at the same row the pivot tables stop.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default When to Stop

Assume the formula is in Cell H5
Dim rng as Range, lastRow as Long
set rng = Activesheet.PivotTables(1).TableRange1

lastrow = rng.rows(rng.rows.count).row
Range("H5:H" & lastrow).Formula = Range("H5").formula

--
Regards,
Tom Ogilvy

"Keith" wrote in message
...
I have a macro that updates two pivot tables that are side
by side. Next to the tables is a calculated field based
on the two tables. Once the tables have been updated the
column with the calculated field needs to have the
calculation copied down to the bottom of the now longer
pivot tables.

Is there anyway to automate this? I need the copying to
stop at the same row the pivot tables stop.



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 stop the "started office live" pop-up to stop. it is checked yrose24 Excel Discussion (Misc queries) 1 September 2nd 09 03:32 PM
Stop (C) becoming © fullers Excel Discussion (Misc queries) 2 May 3rd 06 11:16 AM
Stop % in red Mark Excel Worksheet Functions 7 December 4th 04 01:36 PM
How do I stop other circles in other cells to stop selecting? stauff Excel Worksheet Functions 2 October 29th 04 09:02 PM
How do I stop other circles in other boxes to stop selecting? stauff Excel Worksheet Functions 1 October 28th 04 10:27 PM


All times are GMT +1. The time now is 05:26 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"