moved the set dir to the start of the 'main' procedure
so that ensured that i ran it when i  start the task.
file written
marked up and some editing.