ok thx this was just what i was looking for http://docs.python.org/tut/node7.html#SECTION007600000000000000000