is it possible?? read this!!
#1

is it possible? delete a file using the command in the script
Reply
#2

-.- ...........................

YES, and wrong place
Reply
#3

What do you mean?
Reply
#4

I'm fairly sure it is possible. Yes.
Reply
#5

Quote:
Originally Posted by kloning1
Посмотреть сообщение
is it possible? delete a file using the command in the script
Recreate this thread in the "Scripting Help". With a decent title like.. hmm.. "How to delete a file via a command".

http://forum.sa-mp.com/forumdisplay.php?f=12
Reply
#6

https://sampwiki.blast.hk/wiki/Fremove

Works only for files in the scriptfiles directory of the server for security.
You cant access any files of the clients, and access outside of that server directory is only possible with plugins.
Reply
#7

Yes, it is, if you even tried to use ******. I'll even re-post what the wiki says in-case you're also too lazy to click a link!

Description:
Delete a file.

Parameters:
(name[])
name[] The path of the file to delete. (NOTE: NOT a file handle)

Return Values:
1: The function executed successfully.
0: The function failed to execute. The file doesn't exist, or you don't have permission to delete it.

Important
Note
The file path must be valid.

Note
Files that are currently open (fopen) must be closed first (fclose) to be deleted.

Example Usage:
fremove("Example.txt");
Reply
#8

If you don't want to use the fremove function or the thing you want to delete is a completely different thing, you could simply script a boolean to check whether the file is active or not, if true then the code would continue, if false then it would be the replica of the file being deleted but still being there.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)