Configuring Windows Explorer - Command Line OptionsThis is G o o g l e's cache of http://lee.org/reading/computers/Configuring%20Windows%20Explorer%20Command%20Line%20Options.htm as retrieved on Dec 30, 2005 08:58:31 GMT. G o o g l e's cache is the snapshot that we took of the page as we crawled the web. The page may have changed since that time. Click here for the current page without highlighting. This cached page may reference images which are no longer available. Click here for the cached text only. To link to or bookmark this page, use the following url: http://www.google.com/search?q=cache:VKiImB8QmmYJ:lee.org/reading/computers/Configuring%2520Windows%2520Explorer%2520Command%2520Line%2520Options.htm+explorer.exe+command+line+switches&hl=en&gl=us&ct=clnk&cd=3 Google is neither affiliated with the authors of this page nor responsible for its content. These search terms have been highlighted: explorer exe command line These terms only appear in links pointing to this page: switches I found this document very useful. What I use most often is to make a shortcut on my system tray with a target of "%SystemRoot%\explorer.exe /e,c:\". That way, it doesn't open to stupid "My Computer" -lee Configuring Windows Explorer Command Line Options This page was lifted from http://cpcug.org/user/clemenzi/technical/WinExplorer/CommandLineOptions.htm. Parameters are separated by commas. Many combinations are allowed, but only a few examples are given. Explorer.exe c:\ Open directory as a single pain of icons Explorer.exe /e,c:\ Explore drive as 2 lists - directories on left & files on right Explorer.exe /e,/root,c:\ Explore drive without showing other drives Explorer.exe /n,/e,/select Opens showing only drives Explorer.exe /e,/idlist,%I,%L From Folder\..\Explore in the registry %I - ID number %L - Long filename Explorer.exe /e,DriveOrDirectory Explorer.exe /e,/root,directory,sub-directory Explorer.exe /e,/root,directory,/select,sub-directory /e List (explorer) view, Show large icons if missing (Open view) /root Sets the top level folder. /select Specifies that the directory should be selected without displaying its contents. /s ???? /n Do not open the selected directory, no effect on NT /idlist,%I Expects an ID/handle. May help with cacheing. By itself, opens the desktop as icons. /inproc Stops display of window (I don't know why this is useful) Windows Explorer contains 7 icons. In 95 and NT, the 3rd and 4th are different. Use C:\WINDOWS\SYSTEM\SHELL32.DLL for more options. References I have not found a single reference explaining all the options. Some parameters were found by searching the registry, some are from the sources below, and a few are from browsing the executable. C:\WINDOWS\TIPS.TXT (95 only) provides basic command line help. Search for explorer. Additional notes are provided here. Author: Robert Clemenzi - mailto:clemenzi@cpcug.org?subject=WinExplorer - CommandLineOptions.htm URL: http:// cpcug.org / user / clemenzi / technical / WinExplorer / CommandLineOptions.htm =============================================================================== Command Line Switches to Display Special Objects or Folders When Opening Windows Explorer: When running and opening Windows Explorer, Windows Explorer will automatically display and show the content of a folder, by default is typically My Documents in Windows XP and Windows Server, Documents in Windows Vista and Libraries in Windows 7. User can easily change the default folder that Windows Explorer goes to upon running, by knowing the correct CLSID of the folder or special object. Windows Explorer, or rather Explorer.exe or only Explorer, is the Windows Shell program which accepts command-line parameters or switches to pass to it in order to assert certain result of execution. As such, Windows Vista, Windows 7, Windows XP, Windows NT 4, Windows Server 2000, Windows Server 2003 and Windows 2008 users can use the command-link switch to start Windows Explorer which shows a different object or folder, such as Computer, Documents, Control Panel, and etc. Note that some of these special system folders and objects are already available in Start Menu, which is one of the graphic user interface (GUI) parts of the Explorer. For example, in Windows Vista, user can direct access to user folder, Computer, Documents, Pictures, Music, Control Panel and etc right from the Start Menu. The following commands which call specific CLSID namespace of the object or folder is used to change the behavior of Windows Explorer upon running, and can be set in the properties of Windows Explorer shortcut or issue the command directly in Command Prompt. My Computer %SystemRoot%\explorer.exe /E,::{20D04FE0-3AEA-1069-A2D8-08002B30309D} My Documents %SystemRoot%\explorer.exe /N,::{450D8FBA-AD25-11D0-98A8-0800361B1103} Recycle Bin %SystemRoot%\explorer.exe /N,::{645FF040-5081-101B-9F08-00AA002F954E} Network Neighborhood %SystemRoot%\explorer.exe /N,::{208D2C60-3AEA-1069-A2D7-08002B30309D} Default Web Browser or Navigator (IE, Firefox, Safari, Google Chrome) %SystemRoot%\explorer.exe /N,::{871C5380-42A0-1069-A2EA-08002B30309D} Computer Search Results Folder %SystemRoot%\explorer.exe /N,::{1F4DE370-D627-11D1-BA4F-00A0C91EEDBA} Network Search Results Folder %SystemRoot%\explorer.exe /N,::{E17D4FC0-5564-11D1-83F2-00A0C90DC849} Web Folders %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{BDEADF00-C265-11D0-BCED-00A0C90AB50F} Control Panel %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D} Printers and Faxes %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{2227A280-3AEA-1069-A2DE-08002B30309D} Scanners and Cameras %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{E211B736-43FD-11D1-9EFB-0000F8757FCD} Fonts %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{D20EA4E1-3957-11d2-A40B-0C5020524152} Network Connections or My Network Place %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{7007ACC7-3202-11D1-AAD2-00805FC1270E} Administrative Tools %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{D20EA4E1-3957-11d2-A40B-0C5020524153} Tasks Scheduler %SystemRoot%\explorer.exe /N,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{D6277990-4C6A-11CF-8D87-00AA0060F5BF} It's also possible to directly specify the folder or directory for Windows Explorer to show and display when ran, using the same trick to change and set Windows Explorer default folder. Explorer.exe Command Line Syntax %SystemRoot%\explorer.exe [/n][/e][,/root],X,[[/Select],Y] X specifies the object, and optionally with sub-object Y. /e switch showes the left Windows Explorer tree view navigation pane together with the right pane in list view, while /n hides the left navigation pane. When the /root parameter is present, Explorer.eee will explore the root object (X) and objects belonging to X. On the other hand, when the /root switch is not present, Explorer.exe explores the object X, its children, and other Explorer objects as well. /Select switch puts the focus on a file or folder. For example: %SystemRoot%\explorer.exe /N,%WinDir%\System32,/Select,%WinDir%\System32\Ping.exe Command aboves will explore the \Windows\System32 folder and put the focus on the ping.exe program. Tip: Normally, there is no need to specify full path to explorer.exe, which is stored in the Windows folder, obtainable through the environment variable WinDir, as the path already been defined in PATH environment variable, and will be search through accordingly. As such, Explorer will suffice to run the Windows Explorer shell. chris November 5th, 2009 07:51 4 Hi. This doesnt work in Vista. If anyone knows a way to get it working in Vista let me know. 2K, XP, and W7 work good. JediNite October 24th, 2009 08:20 3 Hi, Here is the Command Line Switch for the "Games" folder if anyone is interested. I've tested this in windows 7 and it works %SystemRoot%\explorer.exe /E,::{ED228FDF-9EA8-4870-83b1-96b02CFE0D52} Cheers, JediNite Ed March 25th, 2009 16:48 2 Great resource - thanks a million. What also works is chaining the special names (like "My Documents") with normal folders. I use this now (via a batch file + shortcut) to open Explorer to the "target-folder" in "My Documents": %SystemRoot%\explorer.exe /E,::{450D8FBA-AD25-11D0-98A8-0800361B1103}\target-folder (This also shows the left folder pane view) Just replace "target-folder" with whatever you want! Trick to Open Computer or Documents as Default Instead of Libraries Folder with Windows Explorer on Windows 7 ¯ My Digital Life February 7th, 2009 03:46 1 [...] Now, Windows 7 Explorer will open Documents or Computer directly, skipping and bypassing Libraries, depends on what you set or configure on initial run. There are more special objects and folders that Windows Explorer can open directly to. [...] Leave a Reply ================================================================================ Command Line switches for Windows Explorer explorer [/n] [/e][,/root,object][[,/select],subobject] None Explorer rooted at the Desktop /n Opens a new window. /e Explorer View (default if nothing else is on the command line.) /root,object Starts Explorer with object the top item (normally Desktop is the top item). Eg: explorer /e,/root,c:\ Starts Explorer with the C drive as the only drive available. /select,subobject Selects the specified subobject. Replaceable parameters are %1 (one) which is the short file or folder name and %l (L) which is the long file name. /IDLIST This is an additional parameter that means a Windows internal structure is being passed. eg: Explorer.exe /e,/idlist,%I The %I is a replacable parameter representing an IDLIST. Rooted Views To open an explorer item that starts with a special folder as the top folder, use the following syntax. Where the special folder is a sub folder of the desktop explorer /e,root,::{CLSID of special folder} Where the special folder is a sub folder of another special folder (usually, if not always My Computer) explorer /e,root,::{CLSID of parent}/::{CLSID of special folder} Where the special folder is part of the file system explorer /e,root,path to folder See Namespaces on the Icons Page for a list of CLSIDs for special folders. Examples Note that /select is inconsistent. Sometime the / is required, sometimes it should be left out, and sometimes it doesn't matter. Starts explorer with the Windows folder opened and selected. explorer /e,select,c:\windows Starts explorer with Windows the top level folder and command opened and selected. explorer /e,/root,c:\windows,select,c:\windows\command Starts explorer with Windows the top level folder and Tips.txt showing instead of the file listing. explorer /e,/root,c:\windows,/select,d:\util\beepjunk.txt Starts explorer with My Computer the top level folder and all branches except for drives collapsed. explorer /e,/root,::{20d04fe0-3aea-1069-a2d8-08002b30309d} Starts explorer with C:\ the top level folder. explorer /e,/root,c:\ Starts the Dial Up Networking folder in folder view. explorer.exe ::{20d04fe0-3aea-1069-a2d8-08002b30309d}\::{992cffa0-f557-101a-88ec00dd010ccc48}