-
Notifications
You must be signed in to change notification settings - Fork 0
File_exists
hpgDesigns edited this page Aug 8, 2021
·
1 revision
NOTOC {{-}}
Checks if the given file exists.
- fname: The name of the file that is being checked.
Returns 1 if it exists, 0 otherwise.
'''Note: '''You can be relatively sure of whether or not a file exists while using this. This function utilizes the Windows API to check for the file's existence, instead of trying to open it for reading. (If it had been programmed to test file existence using file reading, a simple permissions denial would cause the program to think the file didn't exist)
if(file_exists('file.txt')) {
show_message('We are alive!');
}This is number 1