Computer Science, asked by TbiaSamishta, 1 year ago

Give syntax of the following command: ATTRIB (Topic: MS-DOS COMMANDS)

Answers

Answered by Missyouu
0
Syntax : Attrib [Drive:] [Path\Filename]

/S changes files in all sub directories of the specified path

+ Sets an attribute

- Clears an attribute

A specifies an archive attribute

H specifies a hidden file attribute

R Specifies a read only file attribute

S specifies the system file attribute



Read-Only (R) prevent files from being modified or deleted by normal DOS commands

Archive (A) Notifies the Backup Command that the file has modified and so it needs to be saved during a backup operation

Hidden (H) Hides the file nae from the default DIR directory listing and prevents most DOS commands from using this file

System (S) Hides a file, marks it as a DOS system file, and prevents most DOS commands from using a file




Example
Attrib +R +H *.EXE

All files with extensions Exercise will become readable and hidden files




Answered by Sidyandex
2

With ATTRIB command one can change the attributes of a file like the read-only, hidden, archive and system.

The syntax changes accordingly and the total syntax is ATTRIB [d:] [path] filename [/S]

ATTRIB [+ R|-R] [+A|-A] [+ H|-H] [+ S|-S] [d:][path]filename [/S] .

One has to use the syntax according to the work that is to be done.

Similar questions