> Thanks Danny, that was spot on.  I actually used os.chdir to change to
> the base directory (which I assigned to a variable) just before the open
> statement.  I don't know if that's 'pythonically' correct but it seemed
> like a simple way to do it. Again, thank you for helping me fix this.

I am glad!  I would recommend using os.path.join instead to build absolute
paths, as it's less fragile to external factors.  I think of current
working directory the same way I think of global variables: use it
judiciously.
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to