I'm trying to run the following code when an android activity is created, so that two files will be deleted.
protected void onCreate(Bundle savedInstanceState) {
File file = new File (CSQ1.likes_filename);
file.delete();
file = new File (CSQ1.answers_filename);
file.delete();
// Rest of onCreate function
}
Seems simple enough, but it doesn't work. What am I doing wrong?