Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
This may help
#define TRUE .T.
#define FALSE .F.
*--------------------------------------------------------------------------
#define INVALID_FILE_ATTRIBUTES (-1)
#define FILE_ATTRIBUTE_READONLY 0x00000001
#define FILE_ATTRIBUTE_HIDDEN 0x00000002
#define FILE_ATTRIBUTE_SYSTEM 0x00000004
#define FILE_ATTRIBUTE_DIRECTORY 0x00000010
#define FILE_ATTRIBUTE_ARCHIVE 0x00000020
#define FILE_ATTRIBUTE_ENCRYPTED 0x00000040
#define FILE_ATTRIBUTE_NORMAL 0x00000080
#define FILE_ATTRIBUTE_TEMPORARY 0x00000100
#define FILE_ATTRIBUTE_SPARSE_FILE 0x00000200
#define FILE_ATTRIBUTE_REPARSE_POINT 0x00000400
#define FILE_ATTRIBUTE_COMPRESSED 0x00000800
#define FILE_ATTRIBUTE_OFFLINE 0x00001000
#define FILE_ATTRIBUTE_NOT_CONTENT_INDEXED 0x00002000
declare Integer GetFileAttributes in win32api string @
declare Integer SetFileAttributes in win32api string @, Integer
function FileResetReadOnly(FileName)
local fa
fa = GetFileAttributes(@m.FileName)
if( m.fa == INVALID_FILE_ATTRIBUTES )
return FALSE
endif
if( empty(bitand(m.fa, FILE_ATTRIBUTE_READONLY)) ) && file was not readonly
return FALSE
endif
fa = bitand(m.fa, bitnot(FILE_ATTRIBUTE_READONLY))
if( empty(SetFileAttributes(@m.FileName, m.fa)) )
return FALSE
endif
endfunc
*--------------------------------------------------------------------------
function FileSetReadOnly(FileName)
local fa
fa = GetFileAttributes(@m.FileName)
if( m.fa == INVALID_FILE_ATTRIBUTES )
return FALSE
endif
fa = bitor(m.fa, FILE_ATTRIBUTE_READONLY)
if( empty(SetFileAttributes(@m.FileName, m.fa)) )
return FALSE
endif
endfunc
#define TRUE .T.
#define FALSE .F.
*--------------------------------------------------------------------------
#define INVALID_FILE_ATTRIBUTES (-1)
#define FILE_ATTRIBUTE_READONLY 0x00000001
#define FILE_ATTRIBUTE_HIDDEN 0x00000002
#define FILE_ATTRIBUTE_SYSTEM 0x00000004
#define FILE_ATTRIBUTE_DIRECTORY 0x00000010
#define FILE_ATTRIBUTE_ARCHIVE 0x00000020
#define FILE_ATTRIBUTE_ENCRYPTED 0x00000040
#define FILE_ATTRIBUTE_NORMAL 0x00000080
#define FILE_ATTRIBUTE_TEMPORARY 0x00000100
#define FILE_ATTRIBUTE_SPARSE_FILE 0x00000200
#define FILE_ATTRIBUTE_REPARSE_POINT 0x00000400
#define FILE_ATTRIBUTE_COMPRESSED 0x00000800
#define FILE_ATTRIBUTE_OFFLINE 0x00001000
#define FILE_ATTRIBUTE_NOT_CONTENT_INDEXED 0x00002000
declare Integer GetFileAttributes in win32api string @
declare Integer SetFileAttributes in win32api string @, Integer
? FileSetReadOnly([c:\test]) && Just make sure you have C:\TEST folder
function FileResetReadOnly(FileName)
local fa
fa = GetFileAttributes(@m.FileName)
if( m.fa == INVALID_FILE_ATTRIBUTES )
return FALSE
endif
if( empty(bitand(m.fa, FILE_ATTRIBUTE_READONLY)) ) && file was not readonly
return FALSE
endif
fa = bitand(m.fa, bitnot(FILE_ATTRIBUTE_READONLY))
if( empty(SetFileAttributes(@m.FileName, m.fa)) )
return FALSE
endif
endfunc
*--------------------------------------------------------------------------
function FileSetReadOnly(FileName)
local fa
fa = GetFileAttributes(@m.FileName)
if( m.fa == INVALID_FILE_ATTRIBUTES )
return FALSE
endif
fa = bitor(m.fa, FILE_ATTRIBUTE_HIDDEN)
if( empty(SetFileAttributes(@m.FileName, m.fa)) )
return FALSE
endif
endfunc
fso= CREATEOBJECT ('Scripting.FileSystemObject')
fld=fso.CreateFolder("Dummy")
fld.Attributes = fld.Attributes + 2
Therefore I see unregistering FSO as a false step.