Added csv file modification on deletion of file and reading deletion and performing the same

Corrected many small bugs that were forcing close on trying to perform deletion from file