Window Manager: Behind the curtains with Explorer 2000

Almost every Windows user eventually needs to use Explorer to manage files. But Microsoft makes it very hard for people to find out how to configure the thing the way they want it.

A search of the Help system in Windows 98 and 2000 reveals nothing about Explorer's "secret switches". They're clearly explained in the Explorer chapter of Windows 98 Secrets, but we left these details out of Windows 2000 Secrets, because my co-authors and I didn't want to duplicate material in both books.

Now that a whole new generation of users is grappling with Windows 2000, this is a good time to look behind the curtain of our workaday friend, Windows Explorer.

In Windows 2000, Explorer frustrates many people by starting up with its focus on My Documents. Windows 98 Explorer, by contrast, starts up focused on C: drive.

To change these default behaviours of Explorer, you need the secret.

Locate your Windows Explorer shortcut right now. (Look under Start, Programs in Windows 98 or, in Windows 2000, Start, Programs, Accessories.) Right-drag this shortcut from its original location and drop it on the Start button. Finally, click Copy to make a duplicate item right on your Start menu. Apply changes to this duplicate, and you'll still have your original one to go back to, if desired.

Once you have your new Explorer shortcut on your Start menu, right-click it, then click Properties. In Windows 2000, you'll see this command line: %SystemRoot% \explorer.exe. In Windows 98, you'll see something such as the following: c:\windows \explorer.exe /n, /e, c:\.

This latter command line hints at the parameters that Explorer supports. The syntax of these parameters is as follows (I've eliminated the path for brevity's sake): explorer {/n} {,/e} {,/root, x} {{,/select}, y}.

The /n switch opens a new Explorer window, even if an existing window is open. The /e switch specifies a two-pane Explorer view, rather than a single pane. Note that commas are necessary between parameters.

The /root and /select switches make things interesting. You use /select - followed by file, folder, or computer name y - to highlight the selected object and put Explorer's focus on its parent. You use /root in the same way, followed by x, to open Explorer with object x fixed at the "top" of the tree view.

You would typically use the /select switch to make Explorer start with a specific folder or drive selected. By contrast, the /root switch, which is used less often, makes Explorer display a window in which the "root" you've specified is as high as you can go.

Here are some examples. The following command line would start Explorer with the Docs folder open and the file Today.doc selected: explorer /n, /e, /select,c:\docs \today.doc.

Perhaps you don't need to select a specific file but only want Explorer to focus on a different drive letter to the default. In that case, you can dispense with the optional /select switch and simply name the drive.

For example, the following command line would cause Explorer to open with its focus on the D: drive, which might be your CD-ROM or other device: explorer /n, /e, d:\.

The following /root command would start Explorer with Server1 at the top of the tree: explorer /n, /e, /root, \\server1.

Try these for yourself. You can easily make several Explorer shortcuts, one for each drive, one for special folders, and so forth.

For more details, go to search.support.microsoft.com/kb/c.asp and search for article ID Q237494.

Join the newsletter!

Or

Sign up to gain exclusive access to email subscriptions, event invitations, competitions, giveaways, and much more.

Membership is free, and your security and privacy remain protected. View our privacy policy before signing up.

Error: Please check your email address.

More about Microsoft

Show Comments
[]