| www.delorie.com/djgpp/doc/libc-2.01/libc_146.html | search |
_dos_setfileattr@donoderef()
Syntax
#include <dos.h> unsigned int _dos_setfileattr(const char *filename, unsigned int attr);
This function sets the attributes of given file. Use the following constans in DOS.H to create attr parameter:
_A_NORMAL (0x00)
_A_RDONLY (0x01)
_A_HIDDEN (0x02)
_A_SYSTEM (0x04)
_A_VOLID (0x08)
_A_SUBDIR (0x10)
_A_ARCH (0x20)
See section _dos_getfileattr.
Returns with 0 if successful and DOS error value on error (and sets errno to ENOENT or EACCES).
if ( !_dos_setfileattr("FOO.DAT", _A_RDONLY | _A_HIDDEN) )
puts("FOO.DAT is hidden now.");
Go to the first, previous, next, last section, table of contents.
| prev next webmaster | delorie software privacy |
| Copyright © 1997 | Updated Apr 1997 |