Tables, PivotTables, and Macros: music to your ears

Share

Facebook
Twitter
LinkedIn

Howdy folks. Jeff Weir here again. You may remember me from posts such as What would James Bond have in his Personal Macro Workbook and my now infamous music review. Today – and this truly will be music to some ears – we’re going to concentrate more on the former and less on the latter.

Today we’re going to talk about that mystical place where hard tasks just disappear into thin air. Where is that place, I hear you ask? (I have supernatural powers). In that famed triangle of folk-law, of course:
Chandoo_Tables, PivotTables, and Macros_Bermuda

No, not that one. Stop jumping to conclusions and pay attention, will you! This one:

Chandoo_Tables, PivotTables, and Macros_triangle

Suddenly not quite as intrigued? Well, sure…if you add these three things together, no compasses go haywire, no spooky fog will obscures all physical features, and no planes, ships, or movie budgets will go missing. But plenty of tedious mind-numbing pivot-table formatting will disappear. Because combining these three things together in the right way could quite possibly remove ship-loads of needless clicking from your day. Let me explain.

Turn the Tables on Excel

The problem with Excel is that it is so damn high-maintenance: if you add new data to a spreadsheet, you might have to adjust the references in dozens of formulas and charts that point to the original data, so that the new items show up in your calculations and charts.

That’s where Tables come in. Excel Tables – known as ListObjects to VBA developers – were introduced in Excel 2007, and if you’re not familiar with them then I strongly suggest you check out Chandoo’s Introduction to Structural References and this great video he did with MrExcel.

A large part of their appeal is that they spookily expand to accommodate anything you put in them. Even better, anything pointed at that table – Formulas, Charts, Data Validation lists – gets automatically updated at the same time. Here, let’s look at an image, shall we?

Here’s a table that also has a formula, some Data Validation, and a Chart pointed at it. As you can see, whatever is in that table shows up in that formula, validation, and chart too.

Chandoo_Tables, PivotTables, and Macros_Before

I’ve put a red box underneath the table above, to highlight where we’re shortly going to add some new data. At the moment, the table above has got our weekly diet plan in it: Vege, Fruit, and Meat. Hardly a balanced diet. Watch what happens when we add something new under the table where that red box was…because man cannot live on fruit, veges, and meat alone. Well, not this man anyhow.
Chandoo_Tables, PivotTables, and Macros_New Item

Wow, will you take a look at that: the table expanded automatically to hold our new category of ‘Beer’ (just like my stomach does). And wow…those three things we had pointed at that table all got updated automatically, before we could say ‘Prost’. Spooky!

So how do Tables help with PivotTables?

First, let’s look at life without tables. Let’s say we make a PivotTable out of this ‘traditional’ block of data, and we make it display Total Sales by Region:

Chandoo_Tables, PivotTables, and Macros_CreatePivot

*BING!*

Chandoo_Tables, PivotTables, and Macros_PivotTable

Later on we scroll to the bottom and add a new record for a whole new region:

Chandoo_Tables, PivotTables, and Macros_NewData

…and then we refresh our Pivot:

Chandoo_Tables, PivotTables, and Macros_PivotTable Refresh

*BING!*

Chandoo_Tables, PivotTables, and Macros_Hey no data 2

Ahh, that’s right…when we initially set up our PivotTable, that Create PivotTable dialog box had a hard-coded range in it:

Chandoo_Tables, PivotTables, and Macros_HardCoded Range

…which means we need to click this puppy:

Chandoo_Tables, PivotTables, and Macros_Change Data Source

…and then change the hard-coded reference accordingly so that it includes the new data:

Chandoo_Tables, PivotTables, and Macros_What a drag 2

…and we need to do that each and every time we add new data. Maybe monthly. Maybe weekly. Maybe daily. Maybe for multiple pivot tables. Tedious.
 
 

Take two, with Tables

This time, we’ll turn our source data into an Excel Table first. There’s a couple of icons in the ribbon you can click to create a table – and bizarrely those icons are different – but I like to use the keyboard shortcut of Ctrl + T, which is easy to remember, as T stands for Terrific Table.

Chandoo_Tables, PivotTables, and Macros_Create Table

*BING!*

Chandoo_Tables, PivotTables, and Macros_Table

And now let’s create a PivotTable out of it:

Chandoo_Tables, PivotTables, and Macros_Create Pivot from Table

*BING!*

Chandoo_Tables, PivotTables, and Macros_PivotTable

Now watch what happens when we scroll to the bottom and add the new date for our new record:

Chandoo_Tables, PivotTables, and Macros_Table New Data 2

Well that in itself is pretty nifty. Yep, folks…tables have some smart functionality that in themselves can save you significant faffing around. Now let’s put in the rest of the data for that new record:

Chandoo_Tables, PivotTables, and Macros_Table completed

 
And here’s the punch-line: look what happens when you refresh that Pivot:

*BING!*

Chandoo_Tables, PivotTables, and Macros_Table Refresh3

…and I can tell from here just how excited you are by that from the look on your face (you left your web-cam on again), because…

Chandoo_Tables, PivotTables, and Macros_Never click again

Let’s throw some Macros into the mix

I promised you I was going to save you a ship-load of clicks. So far I’ve saved you…let me see…exactly one. What about them others I promised?

Well, given we’ve just established that Pivots love Tables more than I love this album, let’s whip up a macro that will not only create a PivotTable but also automatically turn the source data range into an Excel Table. Then we can assign it to a handy shortcut key – something like Ctrl + Shift + P (“P” for Pivots…I know what you’re memory is like) – so that all you have to do is select a cell in your raw data and in one keyboard shortcut do two things that otherwise would require several clicks. Now that would be worth reading this far, wouldn’t it!

And while we’re at it, let’s code it up so that if you run it on an existing PivotTable, it will retrospectively turn the source data into a Table if needed, and then re-point the Pivot at that Table. That would be handy too.

But why stop there? How ’bout we get it to do a whole bunch of other tiresome things that we routinely do manually in order to set our Pivots up just the way we like ’em. Because if there’s one thing I just can’t stand about pivots, it’s the huge number of things I have to do every single time when I whip one up in order to get it looking just how I like it.

So – as Prince once said, “Let’s go crazy“:

  • Let’s make it put the PivotTable that we just created at the edge of the used part of the sheet that we’re working in – which is usually right by our data, and usually exactly where I actually want it – rather than having to uncheck that pesky “In New Worksheet” button and then having to manually select the range where I want my new pivot to go;
  • Let’s have it cut that PivotTable with a Ctrl + C, so that if we choose to, we can then navigate to any cell we want and simply hit Ctrl + V to paste it into it’s new home. (And if we choose not to move it, we simply do nothing, because it actually stays where it is unless we actually paste it somewhere else;
  • Let’s change the Report Layout to “Show in Tabular Form” instead of the default “Show in Compact Form” setting that I never use;
  • Let’s turn on the “Repeat All Item Labels” option that I practically always want;
  • Let’s turn off Subtotals, because I almost never need them on any field, let alone all of them;
  • Let’s turn off Grand Totals, because those totals don’t always make sense in the context of my Pivots, and they’re simple enough to turn back on if I do need them;
  • Let’s turn off that really annoying “Autofit Column Width on Update” setting, so that my pivot doesn’t stupidly screw up all my carefully set up column widths each time I refresh it;
  • Let’s turn off the “Save Source Data with file” option. No point saving the PivotCache along with the source data, given it only takes an instant to recreate the PivotCache from scratch in the event that we need to. (More on this here).

Wait a minute Jeff…you missed a really annoying thing…

Oh yeah, so I did. Let’s make the Pivot automatically adopt the same source formatting as the original data has – like Mike does over at the Bacon Bits blog – because if there’s one thing guaranteed to make an Excel user do this:

Chandoo_Tables, PivotTables, and Macros_Ahhhhrgh

…it’s either an off-topic post, or (more likely) this:

Chandoo_Tables, PivotTables, and Macros_Does not match
Chandoo_Tables, PivotTables, and Macros_I hate it 4

Here’s the code that will free you from this Pivot Hell:

Just cut the below code, and paste it into your Personal Macro Workbook. Don’t know what that means? Think I’m speaking gibberish? Head over to my earlier post What would James Bond have in his Personal Macro Workbook to find out just how easy this is, and you’ll be a ninja plus in no time!



Sub InstantPivot()

'   InstantPivot: Just Add Water
'   Assign this to Ctrl + Shift + P or something like that.

'   Description:    * Turns selection into Excel ListObject
'                   * Makes a Pivottable out of it at the edge of the used range
'                   * Applies my preferred default settings
'                   * Selects the Pivot and cuts it, so that
'                     you can then use arrow keys
'                     and Control + V to paste it where you wants
'                     without having to touch that unclean dusty rodent
'                     you keeps at the edge of your Desk.Usedrange
'


'Here's the settings it applies.
'   1.  Changes the Report Layout to "Show in Tabular Form"
'   2.  Turns on  "Repeat All Item Labels" option
'   3.  Turn off Subtotals
'   4.  Turn off Grand Totals
'   5.  De-selects the Row Headers option from the Design tab.
'   6.  Turns off 'Autofit Column Width on Update'
'   7.  Turns off 'Save Source Data with file' option.
'   6.  Adopts the source formatting


'   Programmer:     Jeff Weir
'   Contact:        weir.jeff@gmail.com or jeff.weir@HeavyDutyDecisions.co.nz

'   Name/Version:   Date:       Ini:   Modification:
'   InstantPivot    20140213    JSW     Initial programming
'   InstantPivotV2  20140216    JSW     Added error handler and check for multiple cells
'   InstantPivotV3  20140216    JSW     Adopted SNB's approach of setting numberformat while turning subtotals off
'   InstantPivotV4  20140216    JSW     If run on existing pivot that is not based on ListObject, turns source into ListObject
'   InstantPivotV5  20140216    JSW     Now ignores Values fields and doesn't apply format if pf.function = xlCount
'   InstantPivotV7  20140216    JSW     Now ignores Values fields and doesn't apply format if pf.function = xlCount

'   Inputs:         None

'   Outputs:        PivotTable is formatted accordingly. World recognizes my genius and forgives me my occasional off-topic post.

    Dim pc As PivotCache
    Dim pf As PivotField
    Dim pt As PivotTable
    Dim lo As ListObject
    Dim rng As Range
    Dim strLabel As String
    Dim strFormat As String
    Dim i As Long
    Dim wksSource As Worksheet

    
    'Check that we're dealing with a version of Excel that supports ListObjects
    ' In fact, play it safe, and ignore Excel 2007.
    If Application.Version >= 14 Then
    

        On Error Resume Next
        Set pt = ActiveCell.PivotTable
        On Error GoTo errhandler
        If pt Is Nothing Then
            Set lo = ActiveCell.ListObject
            If lo Is Nothing Then Set lo = ActiveSheet.ListObjects.Add(xlSrcRange, Selection.CurrentRegion, , xlYes)
            Set rng = Cells(ActiveSheet.UsedRange.Row, ActiveSheet.UsedRange.Columns.Count + ActiveSheet.UsedRange.Column + 1)
            Set pc = ActiveWorkbook.PivotCaches.Create(SourceType:=xlDatabase, SourceData:=lo)
            Set pt = pc.CreatePivotTable(TableDestination:=rng)
        Else:
            'Check if pt is based on a ListObject.
            '  *  If so, set lo equal to that ListObject
            '  *  If not, turn that source data into a ListObject
            On Error Resume Next
            Set lo = Range(pt.SourceData).ListObject
            On Error GoTo errhandler
            If lo Is Nothing Then
                Set rng = Application.Evaluate(Application.ConvertFormula(pt.SourceData, xlR1C1, xlA1))
                Set wksSource = rng.Parent
                Set lo = wksSource.ListObjects.Add(xlSrcRange, rng, , xlYes)
                pt.ChangePivotCache ActiveWorkbook.PivotCaches.Create(SourceType:=xlDatabase, SourceData:=lo.Name)
            End If
    
        End If
    
        With pt
            .ColumnGrand = False
            .RowGrand = False
            .RowAxisLayout xlTabularRow
            .RepeatAllLabels xlRepeatLabels
            .ShowTableStyleRowHeaders = False
            .ShowDrillIndicators = False
            .HasAutoFormat = False
            .SaveData = False
            .ManualUpdate = True
            If ActiveCell.CurrentRegion.Cells.Count > 1 Then
                For i = 1 To .PivotFields.Count - .DataFields.Count 'The .DataField.Count bit is just in case the pivot already exists
                    Set pf = .PivotFields(i)
                    With pf
                        If pf.Name <> "Values" Then
                            .Subtotals = Array(False, False, False, False, False, False, False, False, False, False, False, False)
                            On Error Resume Next
                            .NumberFormat = lo.DataBodyRange.Cells(1, i).NumberFormat
                            On Error GoTo errhandler
                        End If
                    End With
                Next i
            End If
        End With
        
        ' Get DataFields to match the formatting of the source field
        ' Note that this will only be neccessariy in the case that we're
        ' running this code on an existing pivot
        On Error GoTo errhandler
        If pt.DataFields.Count > 0 Then
            For Each pf In pt.DataFields
                If pf.Function <> xlCount Then pf.NumberFormat = pt.PivotFields(pf.SourceName).NumberFormat
                ' Do away with 'Sum of' or 'Count of' prefix etc if possible
                On Error Resume Next
                pf.Caption = pf.SourceName & " "
                On Error GoTo errhandler
            Next pf
        End If
    
        'This needs to go before the .Cut bit, otherwise the .Cut stack gets wiped
         With Application
            .ScreenUpdating = True
            .EnableEvents = True
            .Calculation = xlAutomatic
        End With
          
        With pt
            .ManualUpdate = False
            .TableRange2.Select
            .TableRange2.Cut
        End With
    Err.Clear
errhandler:
            If Err.Number > 0 Then
                With Application
                    .ScreenUpdating = True
                    .EnableEvents = True
                    .Calculation = xlAutomatic
                End With
                MsgBox "Whoops, there was an error: Error#" & Err.Number & vbCrLf & Err.Description _
                         , vbCritical, "Error", Err.HelpFile, Err.HelpContext
            End If
    End If
    
End Sub

What will you do with all your new spare time?

I’m glad you asked. Why, you’ll have PLENTY of extra free time now in which to give my new favorite album a listen:
Chandoo_Why you should close Excel_album

Chandoo_Tables, PivotTables, and Macros_nooooo3

TRANSMISSION ENDS

Chandoo_Why you should close Excel_test pattern

—Redux—
It’s just gone 22 minutes past Midnight here in New Zealand, and I’ve just got back from Tami Neilson’s album release party for her album Dynamite. It certainly was. I’d say sparks were flying off guitarist and co-producer Delaney Davidson’ guitar but that would be poor poetic license. Because in actual fact, blazing chunks of molten steel were flying off of that beast’s bridge.

I’d say that Tami was twice the woman live than she is recorded. And that’s not too far from the truth, because she is 6 months pregnant, and counting. Not that that was any hindrance whatsoever to her belting out an incredible lyric. That baby of hers is going to have one hell of a set of lungs, if genetic predisposition is anything to go by.

And if we focus on the nurture side of the nurture/nature argument, then that baby is going to have one hell-of-a sense of rhythm too, because it had front-row seats to the craftiest drummer I have ever heard. Why at one stage that drummer threw down his sticks and wrestled beats out of that kit with his bare hands like he would wrestle a live bear. And the bear definately came off second best.

And then there’s the bass-player. Not only was he a damn fine singer, but he also had the longest g-string on stage by far. (Explanation: one of the strings on a Bass guitar is tuned to ‘G’, as is one of the strings on a Guitar. And because a Bass Guitar has a longer neck than an electric rhythm/lead guitar, that G-string is longer. I know, it’s a bad joke.) Eligible Bachelor Number Two was his name. Fastest fingers in the west.

Don’t even get me started on Eligible Bachelor Number Three, the rhythm acoustic and fiddle player. Ye-haw and yes-siree does not even begin to cut it as a compliment to this dude. If I still had a soul and a willing buyer for it, I’d only end up with half the riffs this guy can pull off in exchange for it.

What a night.

🙂

Here’s what you missed:

Facebook
Twitter
LinkedIn

Share this tip with your colleagues

Excel and Power BI tips - Chandoo.org Newsletter

Get FREE Excel + Power BI Tips

Simple, fun and useful emails, once per week.

Learn & be awesome.

Welcome to Chandoo.org

Thank you so much for visiting. My aim is to make you awesome in Excel & Power BI. I do this by sharing videos, tips, examples and downloads on this website. There are more than 1,000 pages with all things Excel, Power BI, Dashboards & VBA here. Go ahead and spend few minutes to be AWESOME.

Read my storyFREE Excel tips book

Overall I learned a lot and I thought you did a great job of explaining how to do things. This will definitely elevate my reporting in the future.
Rebekah S
Reporting Analyst
Excel formula list - 100+ examples and howto guide for you

From simple to complex, there is a formula for every occasion. Check out the list now.

Calendars, invoices, trackers and much more. All free, fun and fantastic.

Advanced Pivot Table tricks

Power Query, Data model, DAX, Filters, Slicers, Conditional formats and beautiful charts. It's all here.

Still on fence about Power BI? In this getting started guide, learn what is Power BI, how to get it and how to create your first report from scratch.

28 Responses to “CP024: Customize Excel to boost your productivity”

  1. Robert says:

    I think that the most useful customisation that I utilise frequently is some code I found that allows multiple items to be selected from a data validation list. For example one workbook we use lists the business drivers for a project. Another uses this technique to select the staff involved in a particular project. See http://blog.contextures.com/archives/2009/09/18/select-multiple-items-from-excel-data-validation-list/

  2. Sean Hyland says:

    Another terrific podcast Chandoo! Glad to hear that you, your family, friends and community are recovering well from HurHur.
    You did a great job of covering so many of the customization techniques that I use but one that I really like is the addition of those top portion of the quick access tool bar with items that I use often but are not standard to any of the tool bar options.

    Thank again Chandoo for the terrific website! It definitely is helping to make me awesome in Excel.

  3. Angelo says:

    I customise excel toolbars by inserting an icon and dragging it to the appropriate area.

  4. Bruno says:

    I prefer not to customize (too much).. I use Excel on a work pc, on two pc's at home, and sometimes on other PC's (even on different languages). I've found that if I keep the most "standard" look, I manage to get around on any pc, whatever the language pack.

    The only thing I do is "pinning" the most used files on the Windows taskbar. And even then I sometimes forget what I placed where, and look it up manually anyway...

  5. Jim Peterkin says:

    Hi, Chandoo. Thanks for the complete review of customizations. I use most of the items you mention, such as Options to set the default font to “old” Arial rather than Cambria. I’ve also adapted the QAT, adding a button to Repeat last action as well as ones to close the current workbook and the Excel application. Lastly, I developed a personal Add-in that contains macros and changes the ribbon (via Microsoft’s Custom UI editor) to rearrange buttons for functions I always use and adds a new ribbon tab with buttons for my personal macros. For example, one of my most frequently used macros deletes all rows below and columns to the right of a selected cell and resets the Excel used range value for the worksheet (helpful for when I press Ctrl-End).

  6. Nick says:

    Thank you again for another great podcast! I always learn something from your podcast/Blog/site. I can't believe I never bothered to look at setting the number of sheets excel creates when you open a New workbook. That will save me time everyday!

    I usually create a Personal Macro set to use, as well as creating some custom ribbon and toolbar sets to make my most needed functions handy (I even include some personal macros in these toolbars.) I also spend some time creating some themes to match the Company reporting colors so that my work can easily be incorporated into company communications.

    Thanks for helping me be awesome at Excel everyday!

  7. Mike says:

    Hi Chandoo - excellent podcast. At the moment I only use the quick access tool bar to add not standard icons. But now I have several techniques that I am going to try. Thanks

  8. target says:

    excellent podcast!! not enough users maximise their productivity by making Excel more comfortable to work with!!

    I use many of the techniques already mentioned (personal macro book, customised QAT/ribbon, etc) but but, instead of adding lot's of buttons I find it's better learn and use the relevant keyboard shortcuts instead of adding buttons for all those functions you use all the time (avoid button overload!!).

    Far better to add buttons for functions you don't use often and that are difficult to find/use in their regular guise

    I also use a default 'dashboard' workbook that has hyperlinks to a handful of files I use regularly.

    also maybe worth mentioning creating default workbook/worksheet 'styles' - to do this create a workbook with the formats you want (fonts, page setup, # of sheets, etc) and save it to your excel start folder with the name BOOK (use SHEET for the sheet template). From then on all new books/sheets will have the same basic formatting

  9. Oxidised says:

    Thanks for the podcast Chandoo, glad you are recovering from the typhoon experience.
    Here at work we created 2 template files, a "simple" one and a "large" one. We often have to put together engineering calculations and having these templates makes it so much faster. The simple one has a cover page (used for tracking revisions) and then a sheet set out in our standard format. The large one has the same cover page, then a contents page that has macro buttons to jump to any of the 10 tabs set up in it. And yes, we often use 5-10 tabs when doing our calculations! This makes the navigation much easier and means we can get on with calcs and not have to spend time formatting.

    Thanks and enjoy, Oxi

  10. Filder says:

    Hi Chandoo – I liked this episode. So far I only use quick access bar to add icons for Macros, special paste etc.. Looking forward to explore some of the techniques shared by you. Thanks

  11. Jo says:

    Thanks for the podcast. There's a couple of things I'll have to try.

    I've set up a default workbook that's saved to my excel start directory that contains:
    * corporate colours and fonts
    * a cover sheet
    * modified and expanded cell styles
    * default table and pivot table styles
    * custom page setup settings

    Another thing I've tried is creating chart templates which saves a bit of time.

  12. Desk Lamp says:

    My Quick Access toolbar is jampacked with macros:

    - Save all open spreadsheets
    - Backup the active workbook to another folder. Useful if I'm making big changes to the spreadsheet that i might want to revert later.
    - Copy & Paste special values. Why click two buttons when you can click one?
    - Set my preferred number formatting
    - Format graphs in company colours
    - Apply red/green conditional formatting for growths data. 0% growth is white, 20% growth is green, -20% growth is red
    - Format and apply settings to pivot tables as I like them. E.g. Tabular format, no retained items, no style, etc
    - Sort items in a pivot filter. Standard Excel capability only lets you sort items if they are in rows or columns not in a filter
    - Delete all custom styles. It amazing how many junk styles spreadsheets can accrue, especially when copying in data from other spreadsheets
    - Resize and reposition all comments. I swear comments have a mind of their own, constantly moving to bizarre places.
    - Print in a Userform all external links and whether the links are active. Including those in name manager and in pivot tables that don't show up in the 'Edit links' window.
    - Print in a Userform all HIDDEN name manger names. As a company we need to be careful about what is exposed when we publish spreadsheets.

    These (and more I've not mentioned) save me countless hours during a normal working week!

  13. Thanks for a great podcast. Really useful tips on customisation. The tip on only one sheet instead of three - using that now myself.

    Personally I use customisation for two main purposes. Quick access to functions I use regularly – to state the obvious – but also some functions I use so infrequently I may not be able to quickly find them when I need them. Forms, for example.

    And if I ever need to use a function or command that I have recently learned or used in a new or different way, I add that to the Quick Access Ribbon.

  14. Shah says:

    Hi Chandoo,

    On top all those customization you've mentioned, I also use the Custom UI Editor for Microsoft Office to create my own Ribbon menu buttons in Excel 2007 and hide the default ones. With the help of macros of course, this makes Excel looks and behave like an App.

    Try that to impress your boss !

  15. Ken says:

    Chandoo,

    Until recently, I had only created custom VBA to solve specific problems related to work. I usually placed a shortcut in a new ribbon. Now I am going to use some of the tips that you mentioned to customize one ribbon for all of the common items that I use (like filter, sort, number format, etc.)

    Thank you.

  16. samtheman says:

    Hi Chandoo,

    I really like your podcast. I will appreciate if you continue to do podcast in the future.
    Regarding my customize of excel, I usually keep lot of commands in Quick Access Toolbars (QAT), esp, insert/delete sheet row, insert/delete sheet column,copy, cut, format copying, paste, paste special, paste value, Font color, Fill color, camera tool and open recent file etc. Also I click on click on Developer tab so that it is visible on my tabs.
    When I was studying MBA, I used to do add-ins of Analysis Toolpak but I have not used that Toolpak since I completed MBA.

    Thanking you,

    Sam

  17. Uriel says:

    Hi Chandoo,

    I really like your page and it's the first time I listen your podcast and it's great!!. I use a lot the Quick Access Toolbar and also use personal macros for rutine task and for look-and-feel in corporate colors, but after listen you I will try to costumize the ribbon and also I will work with themes and styles.

    Thanks to inspire us!!.

    Regards from Mexico.
    Uriel

  18. Ahmed says:

    Thank you Chandoo, very useful.
    I have done 3 things to customize my excel,
    Created a new tab and put in it all my frequently used commands.
    Recorded all my repeated activities as macros and I am running this everyday.
    Added the commands I use very very frequently (including the recorded macros) to the QAT.
    Thank you again

  19. Dave says:

    Hi Chandoo,

    Great podcast. I usually do the following to customize my Excel:
    1) I use custom themes and chart & slicer templates
    2) Custom macros in QAT and Ribbon for repetitive tasks
    3) Keep generic VBA routines in a module for use when needed for specific workbooks, I can just copy it into the target workbook.
    Thanks,
    Dave

  20. Jennifer David says:

    Hi Chandoo,
    I have been using the quick access toolbar and it is great for having frequently used features all in one place. As well as macros and those less commonly known features, such as select visable cells when working with hidden rows/columns. The list of all commands available to add to the toolbar is mind numbing.
    I did not know about adding your own tab to the ribbon. I have already begun contructing my own.
    Thank you for the wonderful information.

  21. Jay says:

    Chandoo,
    I mainly use the personal macros. There are a few charts that I update frequently, this requires that I keep the old data and change the range of the chart. Changing the range causes Excel to pick all new colors for my chart. So, one macro reverses this issue.

    Thanks for sharing your awesomeness.

  22. Jorge Supelano says:

    My customization:

    I have three add-ins: Macabacus light for shortcuts (free), XL Campus to work with lots of tabs and the Tableau reshaper add-in (free), to reshape tables in database form.

    I have created and copied macros for:
    Clean formats
    Search and select constants
    Format as constant (I used to do financial modeling)
    Trace dependents simultaneously
    Center across selection (not used anymore since it's in one of the Add-ins)
    Search and select blanks cells
    Select cell A1 in every sheet (before closing the file)
    Protect and unprotect sheets and workbook

    Almost all macros have shortcuts and a dedicated tab in the ribbon.

    As for Excel options themselves:
    Automatic calculations
    Error tracking disabled
    Cursor stays in same cell when Enter is pressed

    And I used to have a Financial modeling template as a predefined sheet where different formats and styles were pre-established

  23. Ravinder Pal Chopra says:

    Dear chandoo

    Thanks for the excellent podcast. I regularly visit your website and have listened to all your podcast which are very informative. I customise my toolbar by using a quick access and inserting icons in toolbar.

  24. Erich says:

    i used all of you suggestions, but have refrained from pinning files to the Recent Workbook List. It bothered me that this pinned files also took over the keybord shortcuts for the last opened files. If I press ALT-F+1, i want to open the last used file, not the file i pinned first.

    I missed a very powerful Excel customization option in your podcast, which i use every day and saves me hours: custom keyboard shortcuts. There are two of them:

    1. Assign a Key combination to a macro (e.g. "Ctrl-Shift-V" for my VBA-procedure "PasteSpecial_Values")
    -> Open the Macro-dialog (Alt-F8) and go to Options, set the key...

    2. Assign a Key combination even to F-Keys (e.g. "F5" for "my_favorite_Macro")
    -> Open VBA-Editor (Alt-F11), go to any Module in your Personal.xlsb and add this code:

    Sub auto_open()
    Application.OnKey "{F5}", "my_favorite_Macro"
    End Sub

    There is no quicker way to call your macro!

  25. Wouter Naert says:

    Hi Chandoo, very excellent podcast.

    I use the quick access toolbar to link my VBA macro's and at the moment I'm experimenting on adding a personal ribbon tab with personal ribbon buttons. I use a Custom UI Editor to do this, it let me link macro's to the buttons used in the personal ribbontab.

    This way for a project dashboard I can add the buttons necessary there and they are attached to the file. So other people opening the file have the same ribbon tab. Looking professional and to quote 'awesome' ;-).

  26. Jackie says:

    Thanks for your prodcast.

    I customize my excel in the ribbon. This allows to feature the items I need

  27. Chris Triplett says:

    Hi Chandoo,

    Would you please link me to your Excel Customization Handbook? I am sure that this will help me in a huge way!

  28. Zee says:

    Hi Chandoo!
    I would love an Excel Customization Handbook! Here is my tip:

    To recreate the CTRL-HOME functionality on Excel for Mac copy and paste the following code into your personal macro workbook. I assigned my code to the hotkey Option-Cmd-G and now it's like I have a "Home" button on my Mac!
    ----------
    Sub GoHome()
    '
    ' GoHome Macro
    ' Simulates Ctrl-Home on a PC
    '
    ' Keyboard Shortcut: Option+Cmd+g

    If ActiveSheet.Type = xlWorksheet Then
    With ActiveWindow
    .ScrollRow = 1
    .ScrollColumn = 1
    .ActivePane.VisibleRange.Cells(1).Select
    End With
    End If

    End Sub

Leave a Reply