you can also use sys.argv[0]
if you're executing your python module as a script, it's best to put a
little footer at the bottom of the script that only runs when the
module is being executed and not imported:
#!/usr/bin/python
def main(path):
# do something with path
if __name__ == '__main__':
import sys
currScript = sys.argv[0]
main(currScript)
-chad
--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/python_inside_maya
-~----------~----~----~----~------~----~------~--~---