.showpageArea a { text-decoration:underline; } .showpageNum a { text-decoration:none; border: 1px solid #cccccc; margin:0 3px; padding:3px; } .showpageNum a:hover { border: 1px solid #cccccc; background-color:#cccccc; } .showpagePoint { color:#333; text-decoration:none; border: 1px solid #cccccc; background: #cccccc; margin:0 3px; padding:3px; } .showpageOf { text-decoration:none; padding:3px; margin: 0 3px 0 0; } .showpage a { text-decoration:none; border: 1px solid #cccccc; padding:3px; } .showpage a:hover { text-decoration:none; } .showpageNum a:link,.showpage a:link { text-decoration:none; color:#333333; }

Kamis, 15 September 2011

Microsoft DOS attrib command

Quick links
About attrib
Attrib allows a user to change the properties of a specified file. Using attrib, the user has the capability of changing the file to have any of the below attributes. Note if you're wanting to change the ACL's of a file see the CACLS command.
Read-only - allowing the file to be only viewed and not written to.
Archived - allowing Microsoft backup and other backup programs to know what files to backup.
Hidden - making the file invisible to standard users.
System - making the file an important system file.
Availability
The attrib.exe command is an external command that is available in the below Microsoft operating systems.
MS-DOS 3.0 and above
Windows 95
Windows 98
Windows ME
Windows NT
Windows 2000
Windows XP
Windows Vista
Windows 7
Syntax
Microsoft Windows 95, 98, and ME syntax
Displays or changes file attributes.
ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] [[drive:][path]filename] [/S]
+Sets an attribute.
-Clears an attribute.
RRead-only file attribute.
AArchive file attribute.
SSystem file attribute.
HHidden file attribute.
/SProcesses files in all directories in the specified path.
Microsoft Windows 2000 and Windows XP syntax
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.
RRead-only file attribute.
AArchive file attribute.
SSystem file attribute.
HHidden file attribute.
/SProcesses files in all directories in the specified path.
/DProcess folders as well.
Microsoft Windows 2000 and Windows XP recovery console syntax
Note: The below options are the available options in the Windows recovery console.
Changes attributes on one file or directory.
ATTRIB -R | +R | -S | +S | -H | +H | -C | +C filename
+Sets an attribute.
-Clears an attribute.
RRead-only file attribute.
SSystem file attribute.
HHidden file attribute.
CCompressed file attribute.
Examples
attrib
Typing attrib by itself will display all files in the current directory and each of their attributes. If any file is hidden it will also display those files.
attrib +r autoexec.bat
Add the read-only attribute to the autoexec.bat file so it cannot be modified until the read only attribute is taken off. This is helpful for important system files or any other file that you do not want to have mistakenly edited or changed by another program.
attrib +h config.sys
Add the hidden attribute to the config.sys file causing it to be not be seen by the average user.
attrib -h config.sys
This command will do the opposite of the above command. Instead of hiding the file it will unhide the file if hidden.
Extended information
DOS directory file attribute bit position and Hex Value with bit positions (7 6 5 4 3 2 1 0). See the file attributes computer dictionary definition for further information about file attributes.
Bit PositionsHexDescription
0 0 0 0 0 0 0 101hRead Only file
0 0 0 0 0 0 1 002hHidden file
0 0 0 0 0 1 0 004hSystem file
0 0 0 0 1 0 0 008hVolume Label
0 0 0 1 0 0 0 010hSubdirectory
0 0 1 0 0 0 0 020hArchive
0 1 0 0 0 0 0 040hReserved
1 0 0 0 0 0 0 080hReserved
Examples

0 0 1 0 0 0 0 121hRead Only, Archive
0 0 1 1 0 0 1 032hHidden, Subdirectory, Archive
0 0 1 0 0 1 1 127hRead Only, Hidden, Archive

Tidak ada komentar:

Posting Komentar

berkomentarlah dengan bijak . . .
terimakasih sebelum nya ...