Debunking yet another bogus Windows tip

Updated 25-May-2005: Finally! Some authoritative input on this issue! Ryan Myers, a developer on Microsoft’s Windows Client Performance Team, wrote a very informative blog post, “Misinformation and the Prefetch Flag,” that clears up several of these issues. I’ve revised some remarks below in accordance with his entry.

In today’s tip of the day, I warned about following advice from so-called Windows experts who don’t really know their stuff. Case in point: the thousands of Web sites that pass along the bogus advice to clean out your Prefetch folder. (No! Don’t do it!)

A commenter who read that tip asked a great question:

What do you think about adding /prefetch:1 to shortcuts? Does it make any difference? I’ve read on several forums to use the switch for quicker application launches but I haven’t really noticed any increase in speed.

I’d never heard of this tweak, so I did a Google search for prefetch switch program shortcuts and found more than 10,000 Web pages that advise making this speedup tweak. In the rest of this post, I explain why they’re all wrong.

Continue reading “Debunking yet another bogus Windows tip”

Tip of the day: Don’t clean out the Prefetch folder

At least once a week I run across some well-meaning soul who passes along a dubious tip designed to enhance the performance of Windows XP. According to these folks, you should clean out the Windows Prefetch folder regularly to improve your system’s performance. They’re wrong, because they don’t understand how this feature works. Even generally reliable sources like Fred Langa can get tripped up. Here’s what you need to know:

The Prefetch folder is not a cache – at least not in the sense that you normally think of when you use that term. This folder contains trace files and layout files that Windows uses in specific circumstances. Trace files describe the exact order in which segments of programs (executable files and dynamic link libraries, including those that make up Windows itself) load. Windows uses this information to launch Windows and Windows programs in the most efficient way possible. Layout files provide a list of files and directories in the order that they are accessed when you start your computer or run a program. The Windows XP Defrag program uses the layout information to arrange these files in a contiguous region of the hard drive. The “prefetching” doesn’t mean that code is being loaded unnecessarily; it means that code is being loaded in the right way, and only when it’s needed.

Cleaning out the Prefetch folder will not improve performance. I have proved this with a stopwatch repeatedly on multiple test systems, and documented the results in Windows XP Inside Out Second Edition. In fact, emptying the Prefetch folder will actually reduce performance, because Windows has to re-create the trace files the next time you run the program. Windows cleans out old files here automatically, and it uses the current information simply as instructions to help load programs more efficiently. If you delete a program, its layout and trace files go unused and are deleted within weeks.

This isn’t the first time I’ve written about the Prefetch folder. I have a detailed write-up on the subject here. Be sure to follow the links to the excellent article by Mark Russinovitch and David Solomon and scroll down to the section entitled Prefetch, which explains how this feature works in very clear detail.

The next time someone tells you that cleaning out the Prefetch folder is a performance-enhancing measure, tell them it just isn’t so.

Tip of the day: Get to the root of an Explorer window

Normally, when you open Windows Explorer, the window opens in your My Documents folder, with all other drives and folders visible in the Folders pane on the left. But if you just want to work with the files in a single folder (with all its subfolders), don’t forget the trick of creating a “rooted” Explorer window that contains only the specified folder and its subfolders. The secret is using the right switches after the explorer.exe command – in this case, /e to open an Exporer window (with folders visible) and /root to restrict the display of folders to only those that are below the folder you specify.

This shortcut, for instance:

%windir%\explorer.exe /e,/root,%userprofile%\My Documents\

shows a “rooted” view of the current user’s My Documents folder.

Try this one to open the Shared Documents folder:

%windir%\explorer.exe /e,/root,%allusersprofile%\Documents

Note in all cases that there is a space after the explorer.exe command but no space between switches and parameters.

Both of these shortcuts take advantage of environment variables. These systemwide shortcuts, identified by the percent signs on either side of the variable name, automatically point to the correct location, based on the current user profile. If you create one of these shortcuts and put it in the Desktop folder in the All Users profile, the shortcut will appear on the desktop of any user and will open properly for each logged-on user, without requiring any customization.

Tip of the day: Quick-pick files in Windows Explorer

When it’s time to clean out a crowded directory, learn these file selection shortcuts for maximum efficiency:

  • Hold down the Ctrl key and click to select or unselect files one at a time.
  • Select one file, then hold down the Shift key and click on another file to select all files between the two you selected.
  • Press Ctrl+A to select all files.

Here’s a shortcut that most people don’t know about. Say you have a folder that’s packed with files and you want to move or delete a large number of those files while keeping just a few. Select the handful of files you want to keep, and then choose Edit, Invert Selection. All the files in the folder except those you originally clicked on are selected and you can go ahead with your file operation.

Tip of the day: Tweak your windows settings

The best of all Windows customizing utilities is free – and it comes from Microsoft. Tweak UI lets you adjust dozens of tiny settings without having to mess around with the registry. Microsoft has released several versions of Tweak UI through the years. The most recent one is version 2.10, which requires Windows XP Service Pack 1 or later or Windows 2003. Download it from the PowerToys for Windows XP page. After installing this utility, you’ll find its icon in the Powertoys for Windows XP group on the All Programs menu.

Using Tweak UI, you can make all sorts of customizations to the Windows interface. In virtually every case, the effect is to add or toggle a registry setting. You could accomplish the same thing by editing the registry manually, but Tweak UI is quicker and eliminates the risk that you’ll inadvertently muck up your registry by mistyping something.

The screen shown here is one of my favorite tweaks. Click the Focus option under the General heading and select the Prevent applications from stealing focus checkbox. This eliminates a common annoyance that occurs when a program running in the background pops up a dialog box unexpectedly. If you’re typing away at full speed, you might accidentally dismiss the dialog box (or worse, select one of its options). This setting prevents these dialog boxes from appearing and flashes the taskbar button instead.

 Tweak_ui

You won’t find any documentation for Tweak UI online, nor is it officially supported by Microsoft. Carl Siechert, Craig Stinson, and I cover many Tweak UI settings in Windows XP Inside Out Second Edition (and the larger Deluxe Edition), including the automatic logon option (which changes the Winlogon key in the registry), the ability to create custom search shortcuts for use in Internet Explorer, and tweaks to change the five icons that appear in the Places bar at the left of common dialog boxes.

There’s lots of other good stuff in Tweak UI, too, like the ability to hide logon names from the Start menu, customize the list of drive icons in My Computer and the list of options in Control Panel, reassign navigation keys on your keyboard, and toggle AutoPlay settings for CDs and other removable drives.

Note: If you use any older version of Windows, including Windows 2000, get Tweak UI 1.33 from Microsoft’s Web site. (Do not use this version of Tweak UI with Windows XP or Windows 2003!) After unzipping the compressed file, you’ll end up with four files. To install Tweak UI, right-click the Tweakui.inf file and choose Install from the shortcut menu. This version of Tweak UI adds an icon to Control Panel and not to the Start menu.

Got a Tablet PC? Get this add-on

Scoble points to the Experience Pack for Windows XP Tablet PC Edition 2005, which was just released today. I’ve just upgraded the hard drive on my Toshiba Portege 3500 to 80GB (up from 40GB), so I’ll have enough room to bring along some recorded TV from my Media Center when I travel, so this tool is especially nice:

Easily copy media files from your home computer (running Windows XP Home, Professional, or Media Center Edition) to your Tablet PC with Media Transfer. Queue up your favorite music, movies, and digital photo albums and copy them over a wired or wireless network. Then off you go, fully stocked with entertainment.

There’s some other interesting stuff too. Definitely worth a look.

Tip of the day: Give your taskbar twice as much room

This is one of my all-time favorite Windows tips, and it’s one of the first customizations I make on a new computer.

After you open more than three or four programs, you’ll have trouble seeing which file or program goes with each taskbar button. Here’s a great solution: increase the height of the taskbar to two lines (or even three), so you can see more buttons. Aim the mouse pointer at the top edge of the taskbar until it turns to a two-headed arrow, then drag up to create an extra row. If your screen resolution is 1024 X 768, you have room for at least two rows; at higher resolutions, you can comfortably use three rows.

After you finish this tweak, you’ll be able to see more taskbar buttons and their text labels. You’ll also find that the small icons in the Quick Launch bar and the system notification area (the “tray” at the right of the taskbar) stack up as well, giving you a lot more room in these areas, too. Even the clock changes appearance. With a two-line taskbar, you see today’s day and date along with the current time.

You may need to unlock the taskbar before you can make any changes. To do so, right-click the system clock and clear the check mark next to Lock the Taskbar). You may also need to “unhide” the Quick Launch bar (right-click any empty space on the taskbar, click the Toolbars menu, and select the Quick Launch option). Drag the right edge of the Quick Launch bar to make it wide enough to hold your icons. Remember to lock the taskbar after you finish.

Tune up your screen fonts

Last October, the Microsoft Typography group released a ClearType Tuner PowerToy. Don’t assume that this is just for notebooks. Tweaking these settings in Windows XP really can make your screen more readable. There’s a downloadable version, or you can use the online ClearType Tuner (because it uses an ActiveX control, the online version works only in Internet Explorer).

To learn more about ClearType, visit this page, which has a readable FAQ and lots of useful technical details.

(Thanks to Microsoft’s Michael Kaplan for pointing this out. If you’re a font geek, you should be reading his blog!)

How to troubleshoot the Blue Screen of Death

Update: If you’re puzzled because you’re getting STOP errors (the Blue Screen of Death) and they scroll off your screen before you can read the details, here’s the solution: Get details about the Blue Screen of Death.

Trying to figure out what’s causing a Windows STOP error (more commonly known as the Blue Screen of Death, or BSOD) can be a challenge. One likely candidate is bad hardware; if the error messages are random and the shutdowns appear unpredictably, you should suspect a faulty power supply or bad RAM.

Another common BSOD cause is a faulty device driver. Typically, you should be suspicious of any installed drivers that are not digitally signed, especially if they were written for an earlier version of Windows.

Windows XP includes a powerful troubleshooting tool called Driver Verifier (Verifier.exe). It’s a terrific way to identify flawed device drivers. It’s also a surefire way to screw up your system if you use it incorrectly. Read on for the details and important cautions.

Continue reading “How to troubleshoot the Blue Screen of Death”

Internet Explorer Compatibility Evaluator

Microsoft’s browser development group has released a new Internet Explorer Compatibility Evaluator:

IECE is designed to help IT professionals evaluate changes in behavior of web applications and web sites caused by the new security features in Windows XP with Service Pack 2 (SP2) and test for compatibility when moving from Windows XP to Windows XP Service Pack 2. It does this by:

  • Identifying issues and blocks to web site functionality
  • Identifying the cause of a block and specific details to identify the location of the problem

After installing Windows XP with SP2 and IECE, you can begin testing web sites and web applications. When a security feature blocks an action, new information will be entered in the test log including details such as:

  • A time stamp
  • The URL where the block occurred
  • The security feature involved
  • The URL zone
  • A link to information on how to fix this error
  • Automatic mitigation (if available)

If you design Web sites, this should be very helpful.