Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Name of the current pivottable from active cell

hi,

I need a macro to resize the column of the **current** pivot table.
All the code sample I have found suppose that you already have the
name of the pivot table to apply any modification.

Is there a way to find the current pivot table from the active cell ?



Here is the code I need to modify:

ActiveSheet.PivotTables("Tableau croisé dynamique1").PivotSelect
"", _
xlDataAndLabel
Selection.ColumnWidth = 9


Thank you for your help

François
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,836
Default Name of the current pivottable from active cell

Try this utility:

http://www.contextures.com/xlPivotPlay01.html


Regards,
Ryan--

--
RyGuy


" wrote:

hi,

I need a macro to resize the column of the **current** pivot table.
All the code sample I have found suppose that you already have the
name of the pivot table to apply any modification.

Is there a way to find the current pivot table from the active cell ?



Here is the code I need to modify:

ActiveSheet.PivotTables("Tableau croisé dynamique1").PivotSelect
"", _
xlDataAndLabel
Selection.ColumnWidth = 9


Thank you for your help

François

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Name of the current pivottable from active cell

Hi,

Thank you Ryan, but I have finally found the solution (at least, **a**
solution):



ActiveCell.CurrentRegion.ColumnWidth = 9



Simple, clear, efficient :-)

Thanks for your answer, I will have a look at your utility if I am in
need of further features.

Regards

François
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
set the background color of the current cell(active cell) kang New Users to Excel 2 July 31st 07 04:48 PM
How to add todays date (static) to the current active cell using m JimmyJam75 Excel Discussion (Misc queries) 5 September 6th 06 11:23 AM
Populate current active cell - Help Please!! Larry Excel Worksheet Functions 0 July 19th 06 10:19 PM
Inesert value of column B of the current row into active cell PPL[_2_] Excel Programming 4 March 5th 06 08:13 PM
Identify current active cell reades Excel Worksheet Functions 6 January 10th 06 12:48 PM


All times are GMT +1. The time now is 08:42 PM.

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"