USING ATTRIB, SUBST, XCOPY, DOSKEY, AND EDITOR - PowerPoint PPT Presentation

1 / 37
About This Presentation
Title:

USING ATTRIB, SUBST, XCOPY, DOSKEY, AND EDITOR

Description:

Sets attribute - Clears attribute. R Read-only. A Archive. S System. H Hidden ... 7.3 Hidden and Archive Attributes (/H /A) with ATTRIB ... – PowerPoint PPT presentation

Number of Views:51
Avg rating:3.0/5.0
Slides: 38
Provided by: DavidS254
Category:

less

Transcript and Presenter's Notes

Title: USING ATTRIB, SUBST, XCOPY, DOSKEY, AND EDITOR


1
Chapter 7
  • USING ATTRIB, SUBST, XCOPY, DOSKEY, AND EDITOR
  • Page 309

2
7.1 File Attributes The ATTRIB Command
  • ATTRIB R -R A -A S -S
  • H -H drivepathfilename /S /D
  • Sets attribute
  • - Clears attribute
  • R Read-only
  • A Archive
  • S System
  • H Hidden
  • /S Processes matching files in subdirectories too
  • /D Processes the folders as well

3
7.2 Activity ATTRIB Command
  • Begin on O drive with your Data Disk
  • Your Turn
  • ATTRIB .99
  • ATTRIB C\.
  • COPY G\WUGXP\.FIL
  • ATTRIB .FIL
  • ATTRIB R STEVEN.FIL
  • ATTRIB STEVEN.FIL

4
7.2 Activity ATTRIB Command
  • DEL STEVEN.FIL
  • COPY G\WUGXP\.XLS
  • DIR .XLS
  • ATTRIB R .XLS
  • ATTRIB .XLS
  • Minimize the Command Window

5
7.2 Activity ATTRIB Command
  • Start/My Computer Double click O drive
    Tools/Folder Options
  • View - scroll down and remove Hide Extensions for
    known file types OK
  • Scroll down to NEW-SUV.XLS file Double click on
    file to open
  • Click in cell A-30 (box below Toyota)
  • Key in Latest Thing
  • Click File and then click Save

6
7.2 Activity ATTRIB Command
  • Click OK
  • Click Cancel (X box on message)
  • Click File and then click Exit
  • Click NO
  • Close My Computer
  • Click to restore the command window

7
7.2 Activity ATTRIB Command
  • Key in CLS
  • COPY STEVEN.FIL BETTE.FIL
  • ATTRIB R BETTE.FIL
  • DEL BETTE.FIL
  • DEL /F BETTE.FIL
  • DIR BETTE.FIL

8
7.3 Hidden and Archive Attributes (/H /A) with
ATTRIB
  • H Hides a file from the directory display
  • COPY and MOVE will not see file!
  • A Archive a file
  • This lets your backup know if the file has
    already been backed up.

9
7.4 Activity Using the H and A Attributes
  • Your Turn
  • COPY G\WUGXP\FI.
  • DIR F.
  • ATTRIB FI. H
  • DIR F.
  • MOVE F. TRIP
  • DIR /AH

10
7.4 Activity Using the H and A Attributes
  • ATTRIB H FI.
  • DIR F.
  • TYPE STEVEN.FIL
  • ATTRIB STEVEN.FIL
  • ATTRIB A R STEVEN.FIL
  • ATTRIB STEVEN.FIL

11
7.4 Activity Using the H and A Attributes
  • COPY TRIP\FRANK.FIL STEVEN.FIL
  • Y
  • TYPE STEVEN.FIL
  • ATTRIB STEVEN.FIL
  • ATTRIB R A STEVEN.FIL
  • ATTRIB STEVEN.FIL

12
7.4 Activity Using the H and A Attributes
  • REN STEVEN.FIL BRIAN.FIL
  • ATTRIB BRIAN.FIL
  • COPY BRIAN.FIL STEVEN.FIL
  • ATTRIB STEVEN.FIL
  • ATTRIB BRIAN.FIL

13
7.5 The SUBST Command
  • SUBST drive1 drive2path
  • Undo with SUBST drive1 /D
  • Use SUBST by itself to see list

14
7.6 Activity Using SUBST
  • Your Turn
  • TYPE ASTRONOMY\MERCURY\DRESS.UP
  • SUBST T O\ASTRONOMY\MERCURY
  • TYPE TDRESS.UP
  • SUBST
  • SUBST T /D
  • SUBST

15
7.7 The XCOPY Command
  • XCOPY This is an external command
  • Source destination then switches
  • This command is faster then the COPY command.
    Why?
  • It is a buffered copy whereas COPY does one file
    at a time.

16
7.8 Activity Using the XCOPY Command
  • Your Turn
  • DIR G\WUGXP\MEDIA
  • DIR G\WUGXP\MEDIA\BOOKS
  • XCOPY G\WUGXP\MEDIA MEDIA /S
  • D
  • DIR MEDIA
  • DIR MEDIA\BOOKS
  • DIR G\WUGXP\.TXT
  • XCOPY G\WUGXP\.TXT /D06-01-00

17
7.8 Activity Using the XCOPY Command
  • A
  • ATTRIB .BUD
  • XCOPY /M .BUD CLASS
  • ATTRIB .BUD
  • COPY FILE2.FP AST.BUD
  • Y
  • ATTRIB .BUD
  • XCOPY .BUD CLASS /M

18
7.8 Activity Using the XCOPY Command
  • Y
  • ATTRIB .BUD
  • COPY G\WUGXP\.TXT
  • A
  • DIR .TXT
  • ATTRIB H SAN.TXT
  • DIR .TXT
  • MD HIDDEN

19
7.8 Activity Using the XCOPY Command
  • COPY .TXT HIDDEN
  • XCOPY .TXT HIDDEN /H
  • A
  • CD HIDDEN
  • DEL .
  • Y
  • DIR
  • DIR /AH

20
7.9 Multiple XCOPY Parameters
  • Advantage of XCOPY is to perform file operations
    on hidden, system and even read-only files

21
7.10 ActivityUsing Multiple XCOPY Parameters
  • Your Turn
  • MD HOLD
  • XCOPY .TXT HOLD /H
  • DIR HOLD
  • DIR HOLD /AH
  • XCOPY \FILE. /L
  • COPY \FILE.
  • ATTRIB .FP R

22
7.10 ActivityUsing Multiple XCOPY Parameters
  • ATTRIB S .CZG
  • ATTRIB .SWT S H R
  • DIR
  • ATTRIB
  • CD \
  • MD HIDDEN2
  • XCOPY HIDDEN HIDDEN2 /S /H /R /E /K
  • CD HIDDEN2

23
7.10 ActivityUsing Multiple XCOPY Parameters
  • ATTRIB /S
  • CD \
  • RD HIDDEN /S
  • Y
  • RD HIDDEN2 /S
  • Y
  • Close the Command Prompt window

24
7.11 DOSKEY
  • External command
  • Memory resident
  • Referred to as a TSR command (Terminate and Stay
    Resident)
  • Has a bunch of switches

25
7.12 Activity Using DOSKEY
  • Your Turn
  • Close current Command Prompt window
  • Open a new Command Prompt window
  • Key in the following
  • O
  • DIR .TXT
  • DIR G\WUGXP\.99
  • VOL
  • DOSKEY /HISTORY

26
7.12 Activity Using DOSKEY
  • DOSKEY /HISTORY gt TEST.BAT
  • TYPE TEST.BAT
  • CD CLASS DIR .BUD CD \
  • DOSKEY bbCD CLASSTDIR .BUDTCD \
  • bb
  • DOSKEY /MACROS gt b.bat
  • TYPE b.bat

27
7.13 The Text Editor
  • Start in a command prompt by using EDIT
  • Creates ASCII text files
  • Similar to Notepad in Windows
  • Has a search ability
  • No formatting ability however

28
7.14 Activity Using the Text Editor
  • Your Turn
  • Close any open Command Prompt windows
  • Open a new Command Prompt window. Right-click
    the title bat. Click Properties.
  • Click the Options tab
  • Clear QuickEdit Mode, click OK
  • Click Modify shortcut that started in this
    window. Click OK
  • O
  • EDIT
  • NOTEPAGE 350 STARTS NUMBERS AT gtgt6ltlt

29
7.14 Activity Using the Text Editor
  • Close welcome message key in the following
  • This is a test.
  • This is more test data.
  • Press CTRL HOME
  • THIS IS MORE DATA.
  • Press the INSERT key
  • My second.
  • Press the INSERT key
  • Click under the first t in the phrase test
    data

30
7.14 Activity Using the Text Editor
  • Hold left mouse button drag to end (no period!)
  • notePage 352 jumps to number gtgt16ltlt
  • Key in meaningless data
  • On Menu bar..click File/Open
  • O\PERSONAL.FIL
  • Click OK
  • Click Search (Menu bar)
  • Click Find
  • In Find What type Jones

31
7.14 Activity Using the Text Editor
  • Click OK
  • Press F3 three times
  • Press ? four times
  • Key in text on page 354 using spacebar to align
  • Click File
  • Click Exit
  • Click No
  • Click Yes
  • Open the Command Prompt editor

32
7.14 Activity Using the Text Editor
  • Click File/Open
  • O\STEVEN.FIL
  • Click View/Split Window
  • Change Frank to Steven
  • Click File/Save
  • Click File/Close
  • Place cursor in top window and click File/Open
  • O\TEST.BAT then click OK
  • Place cursor in bottom window and click File/Open
  • O\B.BAT then click OK

33
7.14 Activity Using the Text Editor
  • In top window, delete first line and last two
    lines
  • In bottom window, alter the line as on page 356
  • Save both files. Close both files. Exit the
    editor.
  • Close Command Prompt. Open Command Prompt. Make
    O\ the default drive.
  • Key in bb
  • Key in B
  • Close the Command Prompt window.

34
7.15 Using Text Data Files
  • Text files are a way of recording data
  • Text files take up very little space
  • Next we will look at spreadsheets

35
7.16 Activity Importing a Text File
  • Your Turn
  • Open the Microsoft Excel Program
  • Click Data
  • Click Import External Data (or Get External Data)
  • Click Import data (or Import Text File)
  • Click in drop down box and navigate to G\WUGXP
  • Double click PLANETS.TXT
  • Click Next

36
7.16 Activity Importing a Text File
  • Click to clear the Tab check box
  • Click the Comma check box
  • Click Next
  • Click Finish
  • Click OK
  • Click File/Exit
  • Click NO

37
Chapter 7 Exercises
  • Blackboard T/F, CP MC Page 362
  • Blackboard PS I Page 363
  • Do PS II Page 369
Write a Comment
User Comments (0)
About PowerShow.com