Step 4.4: Create a folder, move your file into the folder


Step 4.4: Create a folder, move your file into the folder

click to expand

While your project is hardly cluttered at this point (having only two files), I'm sure you can see how a flat project structure will eventually get filled up with files. However, Eclipse is up to the task, allowing you to create folders and move resources between them quite easily.

q 4.4(a) Right-click in the Navigator pane and select New/Folder ...

click to expand
Figure 4.20: Right-clicking anywhere in the Navigator pane allows you to select the New submenu. Then select the Folder... option to bring up the wizard.

It should be no surprise that this brings up a wizard.

q 4.4(b) Enter 'Steps' in the Folder name field and click Finish.

click to expand
Figure 4.21: The New Folder wizard.

You'll see that the Steps folder has been added to your project, as shown in Figure 4.22. Moving the file Step List.txt to the Steps folder is a standard Windows-style drag and drop operation.

click to expand
Figure 4.22: The Steps folder has been created.

q 4.4(c) Left-click on the Step List.txt file and hold the mouse button down.

q 4.4(d) Drag the Step List.txt file to the Steps folder and drop it.

Continue holding the mouse button down and move the pointer towards the Steps folder. You'll see the cursor icon change to a pointer dragging a box. This is the standard drag icon, and indicates that you are dragging the selected item (Step List.txt, which now has a box around it). You drop the file into the folder by moving the pointer onto the folder ”you'll know you've gotten there because the folder is selected ”and then letting go of the mouse button.

There is also a Move... option in the popup menu for a resource that will accomplish the same thing without so much of a need for manual dexterity.

click to expand
Figure 4.23: Dragging the Steps List.txt file and dropping it into the Steps folder.

You'll see that the Steps folder now has something in it, as indicated by the plus sign to its left.

q 4.4(e) Expand the Steps folder.

click to expand
Figure 4.24: The Steps folder is no longer empty.
click to expand
Figure 4.25: It has the Step List.txt file in it!



Eclipse
Eclipse: Step by Step (Step-by-Step series)
ISBN: 1583470441
EAN: 2147483647
Year: 2003
Pages: 90
Authors: Joe Pluta

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