added workingfolder as an argument