reading files in folder

DavidW Blaschke dwblas at yahoo.com
Tue Jun 3 14:32:56 EDT 2003


Here are links that demonstrate os.path.walk.  Note
the use of isfile to distinguish between files and
directories.
  
http://www.faqts.com/knowledge_base/viewphtml/aid/3380/fid/481
http://www.faqts.com/knowledge_base/view.phtml/aid/4541/fid/538
http://www.faqts.com/knowledge_base/view.phtml/aid/4343/fid/538
  
The faqts database has a lot of normal use code.  I
used it a lot when I first started programming in
Python.  The search engine doesn't seem to be
working so you have to page through "Common Problems",
Snippets", etc.
  
Good Luck
David
  
> > --- In python-list at yahoogroups.com, ataraxia2500
> > <messageboardfan1 at y..
> > .> wrote:
> > > I would like to make a function that do
> something
> > to all the text 
> > files that
> > > are in a folder and if that folder contains
> other
> > folders with text 
> > files
> > > the functions would also modify those text
> files. 
> > > is there a simple function that do that?
> > > 
> > > thanx in advance  
> > > -- 
> > >
> >
> http://mail.python.org/mailman/listinfo/python-list
> > 
> 
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! Calendar - Free online calendar with sync to
> Outlook(TM).
> http://calendar.yahoo.com
> 


__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com





More information about the Python-list mailing list