Quoth Gerhard Häring: [...sys.argv[0] test in WinXP...] > C:\>tmp\x.py > C:\tmp\x.py What happens if %PATH% includes c:\tmp, and you invoke it simply as 'x.py', from some other directory? -- Steven Taschuk "The world will end if you get this wrong." staschuk at telusplanet.net -- "Typesetting Mathematics -- User's Guide", Brian Kernighan and Lorrinda Cherry