Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Excel 7.0 Dynamic Pivot Table FORMATTING

Posted on 1998-04-29
6
Medium Priority
?
717 Views
Last Modified: 2010-07-27
In Excel97 the pivot table has the ability to enable fields and format their contents and data anyway you want.  If you click on a field it will select everything related with it.  You can then select a format for that data.  When you refresh the pivot table, the format STAYS.

However, in Excel 7.0, you CANNOT dynamically format.  There isn't an enable function and when you apply formats to the data individually through the "normal" process, they disappear when the table is refreshed.

I would like to find out whatever information i can to get Excel 7.0 to dynamically format (ENABLE FEILDS or produce code that will recognize certain feild names and format the data accordingly, ie..If  TransType (field name) = "revenue" (item in field)  then format with $ and no decimals and have the format REMAIN when the table is refreshed.
0
Comment
Question by:corboy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 

Expert Comment

by:davespitzer
ID: 1603283
What do you mean with refreshing the tabel I don't have a refresh option in excel 7.0? I have the dutch version because I live in the Netherlands but I don't think this will make a difference.
0
 
LVL 1

Expert Comment

by:SteveWood
ID: 1603284
I have had a quick look at this and to be honest I am unable to get the pivot table to take up the formating from the source data.  However if I format the cells in the table in the normal manner, refreshing does not lose the formatting.

Any more details from you would be helpful.
0
 

Author Comment

by:corboy
ID: 1603285
As far as I know Excel 7.0 does not retain formatting in a pivot table UNLESS it is a format created by the "auto-format" tool.  In Excel '97 you have the ability to retain formatting even after refreshing without any problems..  

I am looking to develop some code that would recognize ALL records with for example "transaction" in them.  By record i mean this for example:  Product(ABC)   Client(Micro world)  Revenue(Transaction)  Year (1998)  Jan(1,230) Feb (1,450)

This record has Transaction in the revenue field.  The code needs to recognize that and format ONLY the Jan and Feb fields as Long Intergers with ",000" comma seperator.

The database I am working with needs to also format Income as Currency with two decimal places and other formatting changes.

Any input would be greatly appreciated....Thanks for all the help so far

Cory Straim
0
Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  

 
LVL 2

Expert Comment

by:the_whelk
ID: 1603286
Create a macro in a new workbook that applies the required formats to the cells you want. That may be quite a task at first. Once created you can use this macro every time you want to create your pivot table.

This may be quite useful if require different formatting at different times. As you can have more than one macro and just run the appropriate one for your requirements.
0
 

Author Comment

by:corboy
ID: 1603287
The macro is ONLY useful if the cells are NOT dynamic, however in a pivot table the cells are constantly changing positions depending on how the pivot tables are set up....This pivot table is within a large database.  There are many different users with many different needs.  This will require Code that will reference an specific item in all records that contain it and switch the number format or text format automatically.  A macro will just refernce cells.  This cannot work for this reason.

If the record i want to refernence is in row 2 of the pivot table..and I change the pivot table to where the record is now not there.  The format will remain the same in row two regardless of what record is in it.
0
 

Accepted Solution

by:
jericho052398 earned 300 total points
ID: 1603288
Write a Visual Basic module that produces a new view for the user, in other words the user will not see the pivot table per se, but will instead see a "temporary" worksheet that reproduces the pivot table data with appropriate formats.  This can easily be accomplished by writing the module so that every time a pivot table is produced, the entire sheet is copied and then the "paste special" option is used to paste only the values into a new worksheet. Then, depending on the data types, "if" statements can be used to properly format the data.  The new sheet can be saved or replaced the next time a pivot table command is invoked.
0

Featured Post

Office 365 Training for IT Pros

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
Microsoft has changed the look and feel of Azure AD and Microsoft account sign-in pages so that you will have a more unified look and feel when moving between the two interfaces.
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question