ES2.Delete
public static void Delete(string path, ES2Settings settings=null)
Parameters
[table th=”0″]path,”The Path of the file, folder or data we want to delete. Path can be a file, folder or tag.”
settings,”Optional. A user-created ES2Settings object containing options not specified in path.”[/table]
Description
Deletes the data at the specified path. This path can be a file, folder or a tag.
If deleting a folder, it will also delete all files and folders within that folder.
Note: You cannot delete folders when using Web Player or PlayerPrefs.
Note: You cannot delete from Resources.
C#
/* Check that a file named 'myFile.txt' contains a tag named 'myPosition' before deleting it. */ if(ES2.Exists("myFile.txt?tag=myPosition")) ES2.Delete("myFile.txt?tag=myPosition");
JS
/* Check that a file named 'myFile.txt' contains a tag named 'myPosition' before deleting it. */ if(ES2.Exists("myFile.txt?tag=myPosition")) ES2.Delete("myFile.txt?tag=myPosition");