Tip of the day: Stop wasting paper when printing Web pages

Sometimes you want to print just part of a Web page, but clicking the Print button spits out page after page of information you don’t want or need. Here’s an easy solution that works the same in Internet Explorer and Firefox:

  • Use your mouse to select the text you want to print. 
  • Click File, Print. (Don’t use the Print button!) In the Print dialog box, look for the area labeled Page Range and choose the Selection option.

If the Selection option is grayed out, you forgot to make a selection. Click Cancel and try again.

“Poisoned” media files wrap-up

The other day I mentioned Microsoft’s new Security Advisory service. The first update in the series has been released, and (surprise!) Microsoft Security Advisory (892313) covers the issue of Windows Media files that can serve as vehicles for delivering unwanted software:

In March 2005, Microsoft issued an update to Windows Media Player to address the issue discussed in this advisory. Microsoft was made aware that malicious attackers can potentially create media files that could then trigger the launch of a Web site without further user interaction. This Web site could potentially then try and trick the user into downloading and executing malicious software add-ons, such as spyware. This social engineering attack abuses a by-design feature in Microsoft Windows Media Player Digital Rights Management (DRM) technology that requires users to have a license to playback a media file.

It’s an excellent summary of an issue I’ve been writing about since the beginning of the year, and I hope it’s a sign of a new awareness about this sort of security issue.

(And a tip of the hat to Eric L. Howes, Ben Edelman, Andrew Clover, Suzi at Spyware Warrior, and Ryan Naraine at eWeek for their input on this issue.)

Keeping files in sync

Thomas Hawk has a legitimate complaint about Windows Explorer:

When I try to copy the letter from one drive to my back up, inevitibly (on nearly every letter) I get an I/O device error that stops my copy job. No viruses, no spyware (at least according to MSFT’s own new software, Adaware and Spybot combined).

Why not have smarter OS software that says, hey, guess what, I can’t copy this file, should I just skip it and go on or should I abandon the whole copy job altogether.

I use a program called FileSync to work around this issue. My digital music collection is fully backed up on three different computers with no file copy errors. It’s a very inexpensive shareware program ($15, last time I looked) and works exceptionally well.

Tip of the day: Show hidden files with a simple script

In its default settings, Windows Explorer conceals two types of files: those with the hidden attribute set, and those designated as system files. Some people, including my occasional writing partner Woody Leonhard, think you should always enable the display of hidden files. I don’t agree – in general, I prefer to keep system and hidden files hidden except when I need to solve a particular problem. To change Explorer’s settings so hidden and system files are visible, open any Explorer window and click Tools, Folder Options (or click the Folder Options icon in Control Panel). On the Folder Options dialog box, click the View tab and select the Show hidden files and folders checkbox. Then scroll down a bit further and clear the Hide protected operating system files (Recommended) checkbox. (You’ll have to click past a warning dialog box to make this change.) When you close the dialog box and return to the Explorer window, you’ll see all the files in that folder, including those marked as hidden and system files.

Show_hidden_files

It is annoying to make this change, and equally annoying to undo the change when you’re finished with the current task. So for Windows XP Inside Out, we came up with a script that automates the process. The script examines the registry to see whether hidden files (those with the Hidden attribute set) are displayed in Windows Explorer. If not, it modifies the registry so that hidden files and super-hidden files (those with the System and Hidden attributes set) are displayed. The script also assumes that you probably want the option to edit file name extensions, so it changes settings to make all file name extensions visible as well. If hidden files are already displayed, the script assumes you want to undo the previous set of changes and modifies these three registry values accordingly.

I’ve made the script file available for download in compressed (Zip) format: Click here to download the file, extract it to a convenient location, and run it whenever you want to toggle hidden files.

If you want to view the script contents first, click here to see the text in a separate browser window. Remember to save the script file with the .vbs extension.

When the script runs, it changes the current settings and displays the results in an information box. If the script won’t run properly on your computer, check to see whether your anti-virus or security software is blocking Visual Basic script files.

Tip of the day: A few Task Manager tricks

I’ve been posting Task Manager tips all week (here, here, here, and here), so I’ll finish up with a few of my favorite tweaks and techniques for this valuable utility.

First, I keep Task Manager running all the time. From the Options menu, I choose the Hide when minimized option, which keeps it from displaying a button on the taskbar. Instead, it minimizes to an icon in the system tray which glows green to indicate the percentage of CPU resources in use at any given time. If you see a bright green icon here, you know that something is sucking up the CPU.

I also set Task Manager to stay on top (Options, Always on Top) when it’s in use.

Next, I customize the display of columns on the Process tab. With the Processes tab selected, click View, Select Columns. Most of the choices here are fairly geeky, but the Peak Memory Usage and CPU Time columns can be useful.

Most people don’t realize the Task Manager window is resizable. Drag the right border to the right to make room for more information in each listing; drag the bottom border down to make room for more entries in the list.

Finally, if Task Manager’s menus and status bar disappear from view, don’t be alarmed. You double-clicked on a chart on the Performance or on a border of another tab. To return to normal view, double-click any empty space around the border.

Tip of the day: Identify processes in the task list

Using Task Manager to identify a process that’s taking more than its fair share of CPU or memory resources is a start, but what happens when you can’t identify the specific process causing the problem? That’s likely to occur if a system service starts to spin out of control. In that case, you’ll see the excess resources attributed to a generic process (usually Svchost.exe), with no indication of which service is actually responsible.

Service Host (Svchost.exe) is a core piece of Windows XP code that collects a number of lower-level system-critical services and runs them in a common environment. By gathering multiple functions together, this arrangement reduces boot time and system overhead and eliminates the need to run dozens of separate low-level services.

Because different groups of services have different requirements in terms of system access and security, Windows XP creates a number of different groups. To see a list of which services are associated with each Svchost instance, click Start, click Run, type cmd in the Open box, and press Enter. In the Command Prompt window, type tasklist /svc /fi “imagename eq svchost.exe” (including the quotation marks).

(Note that the Tasklist command is only available with Windows XP Professional. If you have XP Home Edition, you can download the file from here.)

After you gather the names of services running in the context of a Svchost instance, you can do further research to see which one is causing your performance problem.

For more details on how to use the Tasklist command, type tasklist /? at a command prompt.

Tip of the day: Get to know Task Manager

If you use Windows, you should know about Task Manager. This essential system utility allows you to keep track of which programs are running, kill a program or process that has stopped responding, monitor your system’s performance, and keep track of how your system is using memory. The Task Manager utility has been a part of various Windows versions for years, but the version included in Windows XP does more tricks than any of its predecessors. In fact, this week’s tips will focus exclusively on Task Manager functions.

To start Task Manager, press Ctrl+Shift+Escape. (If you use the default settings for Windows XP with Fast User Switching enabled and your computer is not logged on to a domain, you can start Task Manager with the simpler Ctrl+Alt+Delete sequence.)

The Task Manager interface consists of four tabs (a fifth tab, Users, is visible if Fast User Switching is enabled). The Applications tab, shown here, lists every running program that appears as a Taskbar button. It also includes items that run as programs but hide their taskbar buttons and appear only as tray icons when minimized.

Taskman_apps

I don’t know anyone who uses Task Manager to actually manage programs, even though the various buttons and menu items available here offer a full range of options for doing just that: The Switch To button makes the selected program active, for instance, minimizing the Task Manager window. Click Windows, Bring To Front if you want to surface a program or Explorer window that’s currently hiding behind other windows while still leaving Task Manager in the foreground.

The most important use for the Applications tab is to kill a program that isn’t responding. The Status column normally displays “Running” for every program in the list. If you see “Not Responding,” that’s a clue that the program might have hung. (Some programs fail to respond to requests about their status when they’re busy with a CPU-intensive task, so be sure to wait before concluding that the program is hung.) With very rare exceptions, you should be able to kill any program by selecting its entry in the list on the Applications tab and clicking End Task.

Tomorrow: Using Task Manager to monitor performance.

Service Pack 3 for Windows XP?

Well, this is interesting. F-Secure is covering the launch of National Data Security Day in Sweden, with keynote speaker Steve Ballmer:

Mr. Ballmer made some interesting remarks: Microsoft might indeed ship SP3 for Windows XP before longhorn comes out. Also, upcoming version 7 of Internet Explorer should have anti-phishing technology built-in.

Microsoft’s PR people are going to have to interrupt whatever they’re working on this weekend as their pagers and SmartPhones begin buzzing. And buzzing. And buzzing.