On Tue, 1 Mar 2005 15:30:02 +0000, Adam Cripps <[EMAIL PROTECTED]> wrote: > On Tue, 1 Mar 2005 12:52:57 +0100, Ewald Ertl <[EMAIL PROTECTED]> wrote: > > Hi! > > > > Perhaps this could help you: > > > > fileContent=open( "my/file/to/read", "r").readlines() > > > > for line in fileContent: > > print line.strip() # remove leading and trailing whitspace's > > incl. \n > > > > In the loop you could perhaps populate the entry-widgets. > > > > HTH > > > > Ewald > > > > on Tue, 1 Mar 2005 09:22:06 +0000 Adam Cripps <[EMAIL PROTECTED]> wrote : > <snip> > Thanks Ewald - this is what I have so far, with a far from perfect result: File=open( FileName, "r") readlines = File.readlines() intcount = 0 newcontent =[] for line in readlines: print line.strip() # remove leading and trailing whitspace's incl. \n self.contentlist[intcount].set(repr(line.strip)) intcount = intcount + 1
But all the entry fields are filled with these and not the text: <built-in method strip of str object at 0x009983B0> I'm not sure what else to do here... any ideas? Thanks Adam -- http://www.monkeez.org PGP key: 0x7111B833 _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor