Oops, forgot to remove the temporary hard coded daysToScan passed to fileScan. It now uses the actual value entered by the user.