Author Archives: Eileen Kapp

Productivity tip: Excel tables!

I was recently asked to give a 5-minute presentation on any Excel topic for a “Lunch and Learn” session.  Five minutes?!?!?  That is not much time.  And besides, the Internet is chock-a-block full of Excel productivity tips, so how could I narrow it down to just one tip?  Also, I knew very little about the audience except to assume they were professionals who were not daily users of Excel.  They’re not beginners, but they only use Excel occasionally.

I decided the one feature in Excel that most people could be using but aren’t, is Excel tables.  Here’s why you’ll want to use this fButton_FormatTableeature:

  • It is so simple to implement. Just hit Ctrl-T from the keyboard.  (Or use the “Format as Table” button from the Excel ribbon.)
  • Automatically sizes itself to accommodate existing rows and columns (right up to the first fully blank row and blank column).
  • Automatically expands to accommodate a new row or column when you type in cells adjacent to the existing table.
  • Automatically formats your list of data using alternately shaded rows, and a contrasting header row, for easy reading and a pleasant look. (If you don’t like the shading, you can use the Ribbon to change to a different Table Style.)Excel_tables_banded_rows
  • Automatically includes Auto-Filter features (shown as little triangles in each column header).
  • Automatically uses meaningful cell reference names in formulas. Instead of the old cryptic A2 – B2 notation, your formulas will look like [EndTime]-[StartTime].
  • Automatically assigns a range name to the table (you can either accept the default name or change it). The more you use formulas, the more you’ll appreciate range names!
  • … and many more benefits too numerous to list here.

Pretty much the only time I don’t use Excel tables is for information that is not in a list format.  In other words, if it is not in a row-and-column group of related information, for example, some financial reports that use multiple subtotal rows.

Here are a couple of really good (and short!) introductions to how to use Excel tables:
Want to become a Data God? Learn Excel Data Tables
http://chandoo.org/wp/2009/09/10/data-tables/

Or if you prefer video, here’s 8.5 minutes by Chandoo:
Introduction to Excel Tables
http://chandoo.org/wp/excel-tutorial/using-tables/

And a very thorough, concise intro over at Contextures (also includes some video tutorials):
Creating an Excel Table
http://www.contextures.com/xlExcelTable01.html

No Recycle Bin on Windows Server?

Q.  A client asked: If I’m on my local computer, and I delete a document from the server, the document disappears from the folder, but I don’t know where it goes.  It’s not in the Recycle Bin on the server or the one in my computer. Why not?

A.  The way Windows works, only local files get moved to the Recycle Bin. In other words, only files deleted by a user who is on the same computer where the files live. This makes sense if you figure that network drives would normally be getting backed up, so if you accidentally deleted a file from a network drive, you (or your IT support person) would be able to restore it from the latest backup.

Keep in mind that the way “delete” works, is that it marks the space the file was using as being available for other use.  So if you accidentally delete a file from a server, you could try these steps:

  1. Stop working!
  2. Yell to your co-workers to stop working on the server.
  3. Log on to the server and using an “undelete” utility to retrieve the deleted file. There are several simple undelete utilities (available for downloading for free from the Internet) that can recover files this way.

However, the above method is a risky way to run a business.  A more pro-active measure would be to obtain third-party software and install it on any computers with shared drives:

You can use a recycle bin replacement, such as Undelete  by Diskeeper Corporation, to get the file recovery support for shared drives and folders. These third-party programs are all-in-one deletion recovery solutions. Anything that’s deleted from a computer loaded with the program will be moved to the new recycle bin. This even included files deleted by remote network users or files you delete from flash and removable storage devices.
Excerpted fromhttp://www.webopedia.com/DidYouKnow/Computer_Science/network_file_recovery.asp

Hope this helps, or at least illuminates the issue.

On starting a new Excel project

Whenever I start on a new project, if it’s anything like past projects, it will be a safe bet that there is no written documentation for the Excel files the client is using.  The users will do their best to explain it, then it will be up to me to go under the hood and figure out the nitty-gritty of what’s there.

Here are two things I find useful right from the get-go:

The Eight Things You Should Always Check Whenever You Receive an Excel File
www.mbaexcel.com/excel/the-eight-things-you-should-always-check-whenever-you-receive-an-excel-file

RefTreeAnalyser: The Ultimate Formula Auditing Tool
(an Excel Add-in that is well worth the $35 price tag)
www.jkp-ads.com/reftreeanalyser.asp

Give them a try next time you find yourself taking over an Excel file that was developed by someone else!

An Excel formula to calculate Postage Weights

The Question (long version)

Here’s the question as posed by the client in his own words:

I want to use Excel to calculate the total postage needed to mail packages of stuff to customers.  So if they buy one medium T-shirt (10.7 oz) one large T-shirt (13.2 oz) and one pair of socks (2 oz) that all goes into a mailer that weighs 0.5 oz, then I can see that for this order I’ll need postage for 26.4 oz.

The tricky part, since we’re dealing with postage, is that the sum total must ALWAYS round UP to the next full number, no matter how close —  if a package weighs 5.1 ounces, you STILL have to round up to 6 oz.

Similarly (or maybe worse!?)  once you reach 13.1 ounces it becomes 1 lb.  If you reach 1 lb 1 oz, it becomes 2 lbs., etc.

 

The Question (my simplified version)

For 13.0 oz and under, round up to the nearest ounce, all else round up to the nearest pound. How can I calculate this in Excel?

Now do you see why “word problems” are among the most important things you can learn about math?

 

The Answer (just the formula please)

Assuming that the weight in ounces is in cell A1, otherwise adjust accordingly:

=IF(A1<=13,ROUNDUP(A1,0),16*ROUNDUP(A1/16,0))

 

The Answer (including how we got there)

  1. First we work out the part that rounds up to the nearest ounce. You may already know of Excel’s ROUND function, but that rounds to the nearest number which could be either up or down.  It has two related functions:  ROUNDUP and ROUNDDOWN.  For this problem we need this syntax:ROUNDUP ( Number, Num_digits )where
    Number is the value to be rounded up
    Num_digits is the number of decimal places to round the above number to.So in this case, where the weight in ounces is in cell A1, this is what we need for this part of our formula:ROUNDUP(A1, 0)
  2. Now we need to calculate rounding ounces up to the nearest pound. Given that there are 16 ounces per pound, we have:ROUNDUP(16 * A1, 0)
  3. Finally, we need to combine those two parts and use #1 for weights less than or equal to 13 ounces, and #2 for everything larger. Here is the syntax we will use to combine:IF(logical_test, [value_if_true], [value_if_false])The logical_test that decides which calculation to use, is
    A1<=13
    which will evaluate to either true or false.

Putting it all together, we get:

=IF(A1<=13,ROUNDUP(A1,0),16*ROUNDUP(A1/16,0))

How to Remap Ctrl-Y for the VBA Editor

In most applications, Ctrl-Y is the keyboard shortcut for “Redo.”  (This repeats the last action, or if the last action was Undo, then it undoes the undo, which I guess is indeed a repeat of the last action!)

However, in the VBA Editor, Ctrl-Y deletes the current line of code, kind of like a more powerful version of Ctrl-X.

This is a BIG problem for VBA programmers who are very used to keyboard shortcuts.  I tried to find a workaround to this online, but after a fruitless search, decided to take a stab at this myself, and have come up with a solution.

The solution uses an AutoHotKey script, which I have provided below.  AutoHotkey is a free tool you can download and install on your Windows computer.  You will need to know how to create a text file for your script, and where to save it.  You can find a good explanation of these things here:

Turn Any Action Into a Keyboard Shortcut: A Beginner’s Guide to AutoHotkey
http://lifehacker.com/316589/turn-any-action-into-a-keyboard-shortcut

In the above article, you only need to read up through the section “How to Create a Basic Command”.  The only thing I would change about that introduction is to recommend that you use the version called AutoHotKey_L, for the reasons described here:

The Beginner’s Guide to Using an AutoHotkey Script
http://www.howtogeek.com/56481/the-beginners-guide-to-using-an-autohotkey-script/

Note that not all the lines of the script provided below are technically necessary; the lines that start with a semi-colon are just comments (which are nonetheless very useful to have!).

; = = = = = = = = = = = = = = = = = = = = = = = = =
; Map Ctrl-Y to change default behavior
; If the current window is VBA editor, perform a Redo (Alt-E, R)
; Otherwise, let the Ctrl-Y do its default behavior.
; This AutoHotKey script provided by www.kappconsulting.com


$^y::
; You want a $ at the beginning of your hotkey to prevent the endless loop
; that the ^y in your else block will otherwise trigger.
WinGetTitle, Title, A
;MsgBox, The active window is "%Title%".

if SubStr(Title, 1 , 39) = "Microsoft Visual Basic for Applications"
{
;MsgBox, "YES Microsoft Visual Basic for Applications"
MsgBox, "Next will send Alt-E, R to excecute Redo from the VBE menu."
Send !e
Sleep, 100
Send r
}
else
{
;MsgBox, SubStr(Title, 1 , 39)
;MsgBox, "Next will send Ctrl-Y to do its default behavior."
Send ^y
}

return
; = = = = = = = = = = = = = = = = = = = = = = = = =

Get reminded if you forget an email attachment

Do you ever send an email and forget to include the attachment you meant to attach? Here’s how to make sure that never happens again!

If you’re using Outlook 2013…


If you’re using Outlook 2010 or earlier…

  • This free download comes with directions for how to set up and use:

CodeTwo – Outlook Attachment Reminder

http://www.codetwo.com/freeware/outlook-attachment-reminder/

 

It also has the advantage of being able to add, delete, and edit phrases that trigger an attachment alert.

 

 

If you’re using Gmail …

  • Certain phrases in your message will trigger a reminder for the attachment.

http://email.about.com/od/gmailtips/qt/How_to_Get_a_Forgotten_Attachment_Reminder_in_Gmail.htm

 

 

If you’re using other Email programs…

  • Why not search online to find out if you can be reminded when you’ve forgotten to include an attachment?

Dropbox and Access databases

Twice in the past few months, clients have asked me to look at a problem they encountered using an Access database file with Dropbox syncing. The users observed that multiple copies of the database were generated, with a suffix like “(Phil’s conflicted copy 1-24-2012)”. This is what Dropbox does when it finds that two different people changed the same file since the last sync occurred. (Even though that’s not exactly what happens with the Access file, that’s how it gets interpreted by Dropbox.)

If that doesn’t make sense to you, the important thing to know is that this behavior is a known problem. One workaround is to not use Dropbox syncing for the database file, but instead to explicitly move the file out of and into Dropbox for each working session. Of course, this is rather impractical to do in a true multi-user business environment.

As I mentioned, two clients had this problem recently. One was able to use the workaround described above, because their multiple users were not simultaneous users. The other client connected an external drive as a shared drive between their four computers, and moved the Access file out of the Dropbox folder onto the shared drive. In future posts, I may explore some other ways to share a database across multiple users when they are not connected to the same local area network.

Resources

Dropbox – What’s a conflicted copy?

First Things First: Got Recovery Disks?

Remember when new computers came with their own installation disks for the operating system? They don’t anymore, but you still need them. You just have to make them yourself. Haven’t done this yet? Do it today, before you encounter a problem.

Don’t know how? The instructions should be with the documentation that came with your computer. Or, go online to the support web site for your specific computer model to search for directions there. On some computers, double-clicking the icon for the recovery partition (in “My Computer” or “Windows Explorer”) will start a program that enables you to create recovery media. Still no luck? Try one of the links below, depending on what version of Windows you have.

Resources

Mac users can learn about Time Machine here.