Inserting a Blank Row Between Entries in Excel

A sorting solution

Over the years I have had many requests to help people insert blank rows between entries is a list. Apparently there is an import routine that requires it. My normal solution is a macro because it automates the whole process but there is a manual technique that is quick and easy.

Filtering Tip

Make your headings bold.

This tip applies to tables and to the structures you use for charts.

Excel looks for the bold format when it reviews tables and layouts to figure out if your table has a headings row.

You can use Ctrl + Shift + L to add or remove the filter icons to a data table. There is also an icon on Data ribbon tab.

This will work more reliably if the headings are bold.

I use the following keyboard combination on the top left corner of the table.

Ctrl + Shift + right arrow (this selects all the headings)

Ctrl + b (this applies bold to the headings)

Ctrl + Shift + L (to turn on filters)

This combination can be done very quickly.

You can just use Ctrl + Shift + L within the table, but sometimes this applies the filter to the wrong row.

You Can Undo After You Save

I am amazed how few people know this.

Way back in Office 2007 Microsoft changed the Undo List so that it is NOT cleared whenever you save a file.

You can use Ctrl + z or the Undo icon to undo things you did before you saved the file.

If you close the file that obviously clears the Undo List.

Please let people know this as I find so many people in my training sessions do not know things have changed since Office 2003.

This applies to all MS Office apps.


Make Excel VBA Pause

Sometimes when running a macro you need to make sure Excel has had time to do something before progressing.

This is typically in large models were it can take time (a few seconds) to do a specific task eg removing a filter or updating an external data source.

You can pause a macro to allow Excel to do something by using the Wait command.

Application.Wait (Now + TimeValue("0:00:02"))

The above code will pause the macro for 2 seconds.

Ctrl + Alt + F5 Not Working

The keyboard shortcut to Refresh All in Excel is

This refreshes all the data connections in the file in one step.

The problem is that on some systems (like mine) this conflicts with an Intel Graphics hot key.

To turn off the graphics hotkeys right click the Desktop and choose Graphics Options, then Hot Keys then Disable. See below.

Big thanks to StackOverflow for covering this issue – link below.

https://stackoverflow.com/questions/29149366/default-excel-keyboard-shortcut-ctrl-alt-f5-no-longer-works

VBA to Clear a Filter

Using Excel’s built-in filtering can speed up your VBA code.

It is important if you are applying filters that you clear any existing filters before you apply a new filter. Otherwise the existing filters will usually affect a new filter you apply.

The line of code below will remove filters on Sheet1 (Sheet1 is the sheet code name that you see on the left side of the VBA screen – it may not be the sheet tab name).

If Sheet1.FilterMode Then Sheet1.ShowAllData

The .FilterMode property is True if a filter is in place on the sheet and False if not.

The .ShowAllData method will return an error if no filter is in place – hence the use of the If statement.

Instant Format in Excel

You may know the two keyboard shortcuts below for currency and percentage.

But what you may NOT know is a technique that has been around since the early versions of Excel.

The technique allows you to automatically apply these two formats after you type an entry.

It you type $1000 into a cell and press Enter. Excel will automatically apply the $ format to the cell. The $ sign will not display in the Formula Bar – see below.

If you type 2.5% into a cell. Excel will automatically apply the standard % format to the cell. The % sign will display in the Formula Bar – see below.

As I mentioned these are really old skills that have been lost over the years since we no longer have Excel manuals – shows my age.