
Closes a file.
FileClose (filehandle)
(i) filehandle same integer that was returned by FileOpen.
(i) always 0.
; the hard way to copy an ASCII file
testfile1=FileLocate("win.ini")
testfile2=StrCat(FilePath(testfile1),"winini.bak")
old = FileOpen(testfile1, "READ")
new = FileOpen(testfile2, "WRITE")
While @TRUE ; Loop till break do us end
x = FileRead(old)
If x == "*EOF*" Then Break
FileWrite(new, x)
EndWhile
FileClose(new)
FileClose(old)
Message("FileClose",StrCat(testfile1,@CRLF,"backed up to",@CRLF,testfile2))