Creating Icons & Hotkeys

As you may already know, you have many icons on your desktop and in the Start menu that give you access to things on your system. As you work with your system, you will add others as part of the normal operation of your system. Most people begin to wonder how they can create their own icons or delete some of those they have and no longer want. This is the topic of this section of the tutorial.

Warning: This is an advanced topic and if you don't already feel comfortable with Windows 95/98/ME/XP, I would encourage you not to tackle this until you've been through the rest of this tutorial.

It's impossible for me to know exactly what sort of an icon you want to create so let me pick one to use as an example. Suppose I want to access WordPad easily. There are actually several different ways in which we can create an icon for just about anything, but perhaps the easiest way of explaining this is to tell you that the program you run when you bring up WordPad is called wordpad so let's go find that program. Go to the Start menu and click on Search.  In the Search Results dialog box, click on All files and Folders. Type in "wordpad" in the All or part of the file name field and click on Search. The result will be a list of files containing the word "wordpad".

One of these files will be an Application. Right-click on this wordpad file and drag it to your desktop. When you release the right mouse button, you'll get a context sensitive menu containing your options. Select Create Shortcuts Here. You have just created a shortcut to WordPad. Now let's take this a couple of steps further.

The name of the shortcut we've created is "Shortcut to Wordpad". This is okay, but I think it would be more meaningful if we changed the name to just "WordPad" instead. To do this, right-click on the icon and select Rename from the context sensitive menu that you get. This will allow you to change the name.  Type in "WordPad" in place of "Shortcut to Wordpad" and press <Enter>. There! That's better. At this point, you might like to check to make sure the shortcut we've created really works. Try double-clicking on it to make sure WordPad comes up.

Using this new WordPad icon is only slightly better than clicking on the Start button, moving to All Programs, Accessories and then clicking on WordPad. Normal access to WordPad would require a click, moving the mouse until you get to WordPad and then clicking again. Our new icon requires a double-click. You still have to take you hand off the keyboard, grab the mouse and use it to activate WordPad. Suppose we make another change here that will allow us to bring up WordPad without using the mouse.

Right-click on the icon again and select Properties this time. This brings up the WordPad Properties dialog box which allows us to specify how WordPad will run when we use this icon. Notice the Target: and Start in: fields. The Target: field specifies the name and location of the program that is going to be executed. Note that WordPad is in the Program Files, Windows NT, Accessories folder. The Start in: field specifies where WordPad will look initially for any files you want to load or save. Since we set up a special area in which to put our data (see Naming a File), let's change the Start in: field to point to My Documents. The problem here is that My Documents isn't exactly where you think it is.  In Windows XP, it's actually C:\Documents and Settings\Hughes Glantzberg\My Documents.  Earlier version of Windows would have placed it C:\My Documents.

Now, look at the Shortcut key: field. This allows us to specify a key that we can use to activate this shortcut. Go to this field and just press the "w" key. Notice that the field becomes "Ctrl + Alt + W". In other words, in order to activate this icon, we need to hold down the <Ctrl> and <Alt> keys and press the W key. Okay, now click on OK. Try pressing <Ctrl><Alt>w and see if WordPad comes up.

Let's project this concept out a ways. I can foresee creating a bunch of shortcuts like this. Before long, it might be difficult to remember all the shortcuts you create even if you make them meaningful like the <Ctrl><Alt>W for WordPad. Suppose we create a WordPad file that will contain all the shortcuts we create along with what they point to. As a starting point, this file might look like this:

By making the font size large (I used 20), we can print this file and post it next to the screen and use it for a quick reference. Okay, now let's save this file. Because I figure we will want to modify this file every time we create a new shortcut, I placed it in the My Documents folder and named it Shortcuts so it would be easy to find.

Now all we have to do whenever we want to update this file is double-click on the WordPad icon we created and open the Shortcuts file. Neat, eh? Hey, wait a minute. Might it be possible for us to do this all in one operation? Let's go back in to the Properties for our icon again (right-click on the icon and select Properties from the context sensitive menu). Notice that the Target: field contains double-quotes around the full path to the file we are going to execute - "C:\Program Files\Windows NT\Accessories\wordpad.exe". I wonder if we can add the name of the file we want to work with to the end of this. Let's try expanding this field to - "C:\Program Files\Accessories\WORDPAD.EXE" "Shortcuts.rtf". The reason for the double quotes around what we added is that we don't want the system to alter this in any way. In addition, we didn't specify the path to the file. Can you guess why? Think about this. Remember the Start in: field? Isn't that where we placed this file? Sneaky, eh? J If we had placed this file somewhere else on the system, we would have needed to tell the system where to find the file. Okay, time to give this another try to make sure it does what we want. Double-click on the icon and see what happens.

With the change we've made to this icon, perhaps "WordPad" is not the best name for it. Granted it brings up WordPad, but it also loads the file called Shortcuts.rtf as well. Perhaps a better name for this icon would be "Edit Shortcuts". To make this change, simply right-click on the icon and select Rename and type in the new name. While you're at it, I suspect you don't want to use <Ctrl><Alt>W as your hotkey any more. Perhaps <Ctrl><Alt>S would be more appropriate. And don't forget to change your document as well.


 Hughes Glantzberg

Last Revised: 03/13/2005

Created by
The PC Help Desk
(Hughes Glantzberg)