2.1 Working with Files


The tips that follow show you how to predict ” and even change ” how Explorer responds to the dragging and dropping of files. Here's an overview of how drag-drop works in Windows Explorer:

  • If you drag an object from one place to another on the same physical drive ( c:\docs to c:\files ), the object is moved.

  • If you drag an object from one physical drive to another physical drive ( c:\docs to d:\files ), the object is copied , resulting in two identical files on your system. This means that if you drag an object from one physical drive to another physical drive and then back to the first physical drive, but in a different folder ( c:\docs to d:\files to c:\stuff ), you'll end up with three copies of the object.

  • If you drag any file named setup.exe or install.exe from one place to another, Windows will create a shortcut to the file, regardless of the source or destination folder. The exception is if you drag a file named setup.exe into a recordable CD drive, it will be copied. And if you drag a bunch of files of different types (including, say, setup.exe ), the create-a-shortcut rules will be ignored, and they'll just be copied or moved as appropriate.

  • If you drag any file with the .exe filename extension into any portion of your Start Menu or into any subfolder of your Start Menu folder, Windows will create a shortcut to the file. Dragging other file types (documents, script files, other shortcuts) to the Start Menu will simply move or copy them there, according to the aforementioned rules.

  • If you drag a system object (such as a Control Panel icon), a warning is displayed, and a shortcut to the item is created. These objects aren't actually files and can't be duplicated or removed from their original locations.

TIP

figs/frog_climbingxp_tip.gif

To aid in learning the keystrokes, notice that the mouse cursor changes depending on the action taken. A small plus sign [+] appears when copying, and a curved arrow appears when creating a shortcut. If you see no symbol, the object will be moved. This visual feedback is very important; it can prevent mistakes if you pay attention to it.

2.1.1 Controlling Drag-Drop

The best way to control drag-drop is to use a combination of certain keystrokes and the correct mouse button to ensure the desired results every time you drag an object. That way, you don't have to try to predict what will happen based on some rules you won't likely remember.

Copy

To copy an object in any situation, hold the Ctrl key while dragging. If you press Ctrl before you click, Windows assumes you're still selecting files (as Ctrl is also used to select multiple files, as described later in this chapter), so make sure to press it only after you've started dragging but before you let go of that mouse button. Of course, this won't work for system objects such as Control Panel items ”a shortcut will be created regardless. Using the Ctrl key in this way also works when dragging a file from one part of a folder to another part of the same folder.

Move

To move an object in any situation, hold the Shift key while dragging. Likewise, if you press Shift before you click, Windows assumes you're still selecting files, so make sure you press it after you've started dragging but before you let go of that mouse button. Like above, this doesn't apply to system objects like Control Panel icons.

Create a shortcut

To create a shortcut to an object under any situation, hold the Alt key while dragging. Note that this is different than in previous versions of Windows.

Choose what happens each time

To choose what happens to dragged files each time without having to press any keys, drag your files with the right mouse button , and a special menu will appear when the files are dropped. This context menu is especially helpful, because it displays only options appropriate to the type of object you're dragging and the place where you've dropped it.

Undo

Explorer's Undo command (in the Edit menu, as well as available by right-clicking in an empty area of Explorer or the Desktop, or by pressing Ctrl-Z) allows you to undo the last few file operations. If you've copied, moved, or renamed one or more objects, the command will read Undo Copy, Undo Move, or Undo Rename, respectively. Additionally, if your Recycle Bin is configured to store files, Undo Delete may appear.

TIP

figs/frog_climbingxp_tip.gif

If you're doing a lot of copying, moving, and deleting of files, it's hard to know exactly what you're undoing when you use Undo. The easiest way to tell is to click and hold the mouse button over the Undo menu item in Explorer or a single-folder window and look in the status bar (use View Status Bar if it's not visible). This is not available on the Desktop, but luckily, Undo works the same regardless of the folder from which you use it.

2.1.2 Specifying the Destination

Typically, you must have both the source folder and the destination folder open and visible to copy or move an object. Here are some ways to overcome this limitation:

  • Open Explorer (launch Explorer.exe ) or a single folder window (by double-clicking a folder icon) and make sure the folder tree is visible (View Explorer Bar Folders). Or, right-click any folder icon and select Explore. Then, drag one or more items over the tree pane on the left and hold the mouse cursor over the visible branch of the destination folder. After two or three seconds, Explorer automatically expands the branch and makes the subfolders visible. Figure 2-1 illustrates this.

Figure 2-1. Hold dragged files over folders to expand the branches
figs/wxp_0201.gif
  • You can also use cut-and-paste (or copy-and-paste ) to move or copy files, respectively. Select the file(s) you want to copy, right-click, and select Copy to copy the file(s) or Cut to move the file(s). The keyboard shortcuts for the cut, copy, and paste operations are Ctrl-X, Ctrl-C, and Ctrl-V, respectively. Then, open the destination folder (or click on the Desktop), right-click on an empty area (or open the Edit menu), and select Paste . Whether the file is copied or moved ”or a shortcut is made ”depends on the same criteria as if you had dragged and dropped the item.

  • The standard Windows Explorer toolbar has two buttons , Move To and Copy To, that allow you to point to a location when moving and copying, respectively. Select the file(s) you want to move or copy, click Move To or Copy To, and then specify the destination folder in the dialog that appears.

    Unfortunately, these functions can't be found in Explorer's menus or in the context menus of any files or folders; they're only available on the toolbar. If Explorer's toolbar isn't currently visible, go to View Toolbars Standard Buttons to turn it on. By default, the Move To and Copy To buttons are in the sixth and seventh positions on the toolbar, respectively. If they're not, right-click on the toolbar and select Customize. An alternative tool with more options is available as part of Creative Element Power Tools (http://www.creativelement.com/powertools/).

2.1.3 Duplicating Files and Folders

Windows lets you copy and move files from one folder to another by dragging them with different combinations of keystrokes, as described earlier in this chapter. You can also rename a file by clicking on its name or highlighting it and pressing the F2 key. However, if you want to make a duplicate of a file in the sa me directory and assign it a different name, the process might not be as obvious. There are several ways to do it:

  • Hold the Ctrl key while dragging a file from one part of the window to another part of the same window. This works in single-folder windows, on the Desktop, and in Explorer.

  • Use the right mouse button to drag the file from one part of the window to another part of the same window, and then select Copy Here.

  • For keyboard enthusiasts : press Ctrl-C and then Ctrl-V to create a duplicate of a file using the clipboard.

Regardless of which solution you use, duplicates are always assigned new names to avoid conflicts.

If you need a bunch of duplicates of a file or folder, start by duplicating it once. Then, select both the original and the copy, and duplicate them both. Then, select the resulting four objects and duplicate them to make eight.



Windows XP Pocket Reference
Windows XP Pocket Reference
ISBN: 0596004257
EAN: 2147483647
Year: 2001
Pages: 154
Authors: David A. Karp

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net