Re: Directory in Windows

2005-04-30 Thread Marc 'BlackJack' Rintsch
In <[EMAIL PROTECTED]>, custard_pie wrote: > Here's my code > > filelist={} > def listFiles(self, dirName, filesInDir): > for fname in filesInDir: > if os.path.isfile(fname): `fname` contains just the file name without t

Re: Directory in Windows

2005-04-30 Thread custard_pie
Here's my code filelist={} def listFiles(self, dirName, filesInDir): for fname in filesInDir: if os.path.isfile(fname): key = os.path.join(dirName, fname) stats = os.stat

Re: Directory in Windows

2005-04-30 Thread Kent Johnson
custard_pie wrote: Hi,..I tried to list files in a tree directory using os.path.walk. To avoid dirnames fromm being listed i use the os.path.isdir method. However, when isdir encounters directories that use spaces in their name e.q My Documents it doesn;t recognize them as directories.. Is there an