Technical data
Managing a DOS File System
303561-A Rev 00
5-21
To assign a single attribute to a file, use the hex value associated with the attribute
you want in the attribute command. For example, enter the following command to
assign the read-only file attribute to a file named config located in the present
working directory:
attr 0x01 config
To assign multiple attributes to a file, add the hex values associated with the
attributes you want and enter the total in the attribute command. For example, to
assign the attributes archive needed, hidden, and read-only to the config file, add
their associated hex values:
0x20 + 0x02 + 0x01 = 0x23
Then enter the following command to assign these file attributes:
attr 0x23 config
You can also assign attributes to a file in another directory by specifying the path
name. For example, enter the following command to change the file attributes of a
file named l6_23.log in the logs path:
attr 0x23 \logs\l6_23.log
Examples:
attr 0X01 config
Sets the attribute of the file
config
to read-only
attr 0X03 config
Sets the attributes of the file
config
to hidden and read-only
attr 0X23 config
Sets the attribute of the file
config
to hidden, read-only, and
archive needed