Hi, I use this: # This is the file name this code is in curfile = "findcurdir.py" #__file__ gives everything so slice off the file name curdir = __file__[:-len(curfile)] print curdir #will print the curdir the file is in #even if this file(module) has been imported I hope it helps Laszlo Antal