added function to read file name from the file and get respective file name