SetFileAttributes()

Syntax

Result = SetFileAttributes(Filename$, Attributes)
Description
Set the attributes of the given Filename$. If 'Result' is 0, then the attributes of the file can not be changed. The 'Attributes' are a combinations of the following values:
  #PB_FileSystem_Hidden    : File is hidden
  #PB_FileSystem_Archive   : File has been archived and not changed since the last time
  #PB_FileSystem_Compressed: File is compressed
  #PB_FileSystem_Normal    : Normal attributes
  #PB_FileSystem_ReadOnly  : File is in readonly mode
  #PB_FileSystem_System    : File is a system file
To combine several attributes, just use the '|' (binary OR) operand:
  SetFileAttributes("C:\Text.txt", #PB_FileSystem_Hidden | #PB_FileSystem_ReadOnly)

Supported OS

All

<- SetCurrentDirectory() - FileSystem Index - SetFileDate() ->