writing events as csv for all files in project