The docs even say "This function fails if the file cannot be opened with write permission" which is certainly the case here.
My app depends on users being able to save data wherever they want, so I can't say "Saved successfully!" if it didn't.
Code: Select all
f=CreateFile(#PB_Any,"c:\test.txt")
If f
WriteStringN(f,"Add")
CloseFile(f)
Debug "Success!" ; Actually failure.
EndIf
Code: Select all
f=OpenFile(#PB_Any,"c:\test.txt",#PB_File_Append)
If f
WriteStringN(f,"Add")
CloseFile(f)
Debug "Success!" ; Actually failure.
EndIf


