put the result into lastResult
-- Delete The Results Directory, extracting it from the log file name
put lastResult.LogFile into logFolder
delete the last item delimited by "/" of logFolder
delete folder logFolder
-- Raise an Error if our sub script did not succeed
if (lastResult.status is not "Success") then throw "Script Failed"