pasang iklan

Translate

English French German Spain Italian Dutch Russian Portuguese Japanese Korean Arabic Chinese Simplified

Kajian Perintah DOS

Posted by Iyan On Jumat, Maret 18, 2011 No comments


ATTRIB
Menampilkan atau mengubah atribut suatu file.
Kita lihat format perintahnyaC:\Documents and Settings\labkom>attrib /?
Displays or changes file attributes.
ATTRIB [+R | -R] [+A | -A ] [+S | -S] [+H | -H] [drive:][path][filename]
[/S [/D]]
+   Sets an attribute.
-    Clears an attribute.
R   Read-only file attribute.
A   Archive file attribute.
S    System file attribute.
H   Hidden file attribute.
[drive:][path][filename]
Specifies a file or files for attrib to process.
/S  Processes matching files in the current folder and all subfolders.
/D  Processes folders as well.
contoh : misalnya kita ingin mengilangkan file-file di drive H yang telah diberi atribut read(r), system (s), disembunyikan/hidden(h) dan arsip(a) maka perintahnya adalah :attrib -s -r -a -h H:\ /s /dCD / CHDIR
Menampilkan nama atau mengubah direktori sekarang
Bentuk umumDisplays the name of or changes the current directory.CHDIR [/D] [drive:][path]
CHDIR [..]
CD [/D] [drive:][path]
CD [..]
..   Specifies that you want to change to the parent directory.Type CD drive: to display the current directory in the specified drive.
Type CD without parameters to display the current drive and directory.
Use the /D switch to change current drive in addition to changing current
directory for a drive.
If Command Extensions are enabled CHDIR changes as follows:The current directory string is converted to use the same case as
the on disk names.  So CD C:\TEMP would actually set the current
directory to C:\Temp if that is the case on disk.
CHDIR command does not treat spaces as delimiters, so it is possible to
CD into a subdirectory name that contains a space without surrounding
the name with quotes.  For example:
cd \winnt\profiles\username\programs\start menuis the same as:cd “\winnt\profiles\username\programs\start menu”which is what you would have to type if extensions were disabled.CMD
Menjalankan interpreter perintah Windows yang baru.
Bentuk umum :Starts a new instance of the Windows XP command interpreterCMD [/A | /U] [/Q] [/D] [/E:ON | /E:OFF] [/F:ON | /F:OFF] [/V:ON | /V:OFF]
[[/S] [/C | /K] string]
/C      Carries out the command specified by string and then terminates
/K      Carries out the command specified by string but remains
/S      Modifies the treatment of string after /C or /K (see below)
/Q      Turns echo off
/D      Disable execution of AutoRun commands from registry (see below)
/A      Causes the output of internal commands to a pipe or file to be ANSI
/U      Causes the output of internal commands to a pipe or file to be
Unicode
/T:fg   Sets the foreground/background colors (see COLOR /? for more info)
/E:ON   Enable command extensions (see below)
/E:OFF  Disable command extensions (see below)
/F:ON   Enable file and directory name completion characters (see below)
/F:OFF  Disable file and directory name completion characters (see below)
/V:ON   Enable delayed environment variable expansion using ! as the
delimiter. For example, /V:ON would allow !var! to expand the
variable var at execution time.  The var syntax expands variables
at input time, which is quite a different thing when inside of a FOR
loop.
/V:OFF  Disable delayed environment expansion.
Note that multiple commands separated by the command separator ‘&&’
are accepted for string if surrounded by quotes.  Also, for compatibility
reasons, /X is the same as /E:ON, /Y is the same as /E:OFF and /R is the
same as /C.  Any other switches are ignored.
If /C or /K is specified, then the remainder of the command line after
the switch is processed as a command line, where the following logic is
used to process quote (“) characters:
1.  If all of the following conditions are met, then quote characters
on the command line are preserved:
- no /S switch
- exactly two quote characters
- no special characters between the two quote characters,
where special is one of: &<>()@^|
- there are one or more whitespace characters between the
the two quote characters
- the string between the two quote characters is the name
of an executable file.
2.  Otherwise, old behavior is to see if the first character is
a quote character and if so, strip the leading character and
remove the last quote character on the command line, preserving
any text after the last quote character.
COPY
Menyalin satu atau beberapa file ke lokasi lain.
DATE
Menampilkan atau mengubah tanggal.
DEL / ERASE
Menghapus satu atau beberapa file.
DIR
Menampilkan daftar file dan subdirektori dalam sebuah direktori.
Bentuk umumnya :DIR [drive:][path][filename] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N]
[/O[[:]sortorder]] [/P] [/Q] [/S] [/T[[:]timefield]] [/W] [/X] [/4]
[drive:][path][filename]
Specifies drive, directory, and/or files to list.
/A          Displays files with specified attributes.
attributes   D  Directories                R  Read-only files
H  Hidden files               A  Files ready for archiving
S  System files               -  Prefix meaning not
/B          Uses bare format (no heading information or summary).
/C          Display the thousand separator in file sizes.  This is the default.  Use  /-C to disable display of separator.
/D          Same as wide but files are list sorted by column.
/L          Uses lowercase.
/N          New long list format where filenames are on the far right.
/O          List by files in sorted order.
sortorder    N  By name (alphabetic)       S  By size (smallest first)
E             By extension (alphabetic)  D  By date/time (oldest first)
G            Group directories first    -  Prefix to reverse order
/P          Pauses after each screenful of information.
/Q          Display the owner of the file.
/S          Displays files in specified directory and all subdirectories.
/T          Controls which time field displayed or used for sorting
timefield   C  Creation
A  Last Access
W  Last Written
/W          Uses wide list format.
/X          This displays the short names generated for non-8dot3 file
names.  The format is that of /N with the short name inserted
before the long name. If no short name is present, blanks are
displayed in its place.
/4          Displays four-digit years
Switches may be preset in the DIRCMD environment variable.  Override
preset switches by prefixing any switch with – (hyphen)–for example, /-W.
DISKCOMP
Membandingkan isi dari dua buah disket.
DISKCOPY
Menyalin isi dari satu disket ke disket lain.
ECHO
Menampilkan pesan, atau mengubah command echoing on atau off.
EXIT
Keluar dari program CMD.EXE dan menutup jendela command prompt.
FC
Membandingkan dua atau beberapa file, dan Menampilkan perbedaan file-file tersebut.
FIND
Mencari string teks dalam sebuah file atau beberapa file.
FORMAT
Mem-Format sebuah hardisk/disket untuk digunakan di Windows.
HELP
Menyediakan informasi bantuan untuk perintah-perintah Windows.
LABEL
Membuat, mengubah, atau menghapus volume label dari sebuah disket/harddisk.
MD / MKDIR
Membuat direktori.
Bentuk umumCreates a directory.MKDIR [drive:]path
MD [drive:]path
If Command Extensions are enabled MKDIR changes as follows:MKDIR creates any intermediate directories in the path, if needed.
For example, assume \a does not exist then:
mkdir \a\b\c\dis the same as:mkdir \a
chdir \a
mkdir b
chdir b
mkdir c
chdir c
mkdir d
which is what you would have to type if extensions were disabled.MOVE
Memindahkan satu atau beberapa file dari satu direktori ke direktori yang lain.
PATH
Menampilkan atau mengatur path pencarian untuk executable files.
PROMPT
Mengubah command prompt Windows.
RD /RMDIRBentuk UmumRemoves (deletes) a directory.RMDIR [/S] [/Q] [drive:]path
RD [/S] [/Q] [drive:]path
/S      Removes all directories and files in the specified directory
in addition to the directory itself.  Used to remove a directory
tree.
/Q      Quiet mode, do not ask if ok to remove a directory tree with /SREN / RENAME
Mengubah nama file.
TIME
Menampilkan atau mengatur waktu sistem.
TREE
Menampilkan secara grafis struktur direktori dari sebuah drive atau path.
TYPE
Menampilkan isi dari sebuah file teks.

0 komentar:

www.blognyaiyan.blogspot.com. Diberdayakan oleh Blogger.