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.
oFolder = GETDIR()
GenerateAllFolderInformation(oFolder)
FUNCTION GenerateAllFolderInformation
LPARAMETERS loFolder
#DEFINE TABSTOP CHR(9)
#DEFINE NewLine CHR(13)
PUBLIC lcText
LOCAL lcSubFolders
LOCAL lcSubFolder
LOCAL lcFiles
LOCAL lcFile
FSO = CREATEOBJECT("Scripting.FileSystemObject")
lcFolder = FSO.getfolder(loFolder)
lcText = "Folder:" +TABSTOP+ lcFolder.PATH+ NewLine+ NewLine
lcFiles = lcFolder.FILES
IF lcFiles.COUNT =1
lcText = "There is 1 file" & NewLine
ELSE
lcText = lcText+ "There are " +TRANSFORM(lcFiles.COUNT)+ " files" +NewLine
ENDIF
IF lcFiles.COUNT <> 0
FOR EACH lFile IN lcFiles
GenerateFileInformation(lFile)
NEXT
ENDIF
STRTOFILE(lcText,"c:\fileinfo.txt")
MODIFY FILE c:\fileinfo.txt
FUNCTION GenerateFileInformation
LPARAMETERS lcFile
lcText = lcText+NewLine + "Path:" + TABSTOP + lcFile.PATH
lcText = lcText+NewLine + "Name:" + TABSTOP + lcFile.NAME
lcText = lcText + NewLine + "Type:" + TABSTOP + lcFile.TYPE
lcText = lcText + NewLine + "Attribs:" + TABSTOP + ShowFileAttr(lcFile)
lcText = lcText + NewLine + "Created:" + TABSTOP + DTOC(lcFile.DateCreated)
lcText = lcText + NewLine + "Accessed:" + TABSTOP + DTOC(lcFile.DateLastAccessed)
lcText = lcText + NewLine + "Modified:" + TABSTOP + DTOC(lcFile.DateLastModified)
lcText = lcText + NewLine + "Size" + TABSTOP + TRANSFORM(lcFile.SIZE) + NewLine
ENDFUNC
FUNCTION ShowFileAttr
LPARAMETER llcFile
ATTR = llcFile.ATTRIBUTES
DO CASE
CASE ATTR = 0
ShowFileAttr = "Normal"
CASE ATTR =1
ShowFileAttr = "Read-Only"
CASE ATTR = 2
ShowFileAttr = "Hidden"
CASE ATTR = 4
ShowFileAttr = "System"
CASE ATTR = 8
ShowFileAttr = "Volume"
CASE ATTR = 16
ShowFileAttr = "Directory"
CASE ATTR = 32
ShowFileAttr = "Archive"
CASE ATTR = 64
ShowFileAttr = "Alias"
CASE ATTR = 128
ShowFileAttr = "Compressed"
ENDCASE
RETURN ShowFileAttr
ENDFUNC