Getting the file to read into function