[Tutor] help

RIDDLE BOX riddlebox@vitalogy.org
Tue, 2 Oct 2001 11:29:51 -0700


Hello,

I may have the been trying to do this wrong with that code, but I would
like the program to look at a file and then when you are done looking at
that file, I would like it to ask if you would like to look at another
file, and keep asking that until you quit the program. this is my whole
code right now. I hope I am on the right track.  thanks for all your help I am pretty sure that my while statement is wrong but I dont know how to get it to work
thanks


    class App:
        def __init__(self, master):

            frame = Frame(master)
            frame.pack()

            self.button = Button(frame, text="quit", fg="blue", 
command=frame.quit)
            self.button.pack(side=RIGHT)

            self.second_chance = Button(frame, text="would you like to look at 
another file?", fg="red", command=self.second_chance)
            self.second_chance.pack(side=LEFT)

        def second_chance(self):
            read = raw_input("where is the file located?")
            inp = open(read, "r")
            for line in inp.readlines():
                print line



root = Tk()

app = App(root)




------------------------------------------------------------
This Email Is Provided Free Of Charge Thanks To http://www.vitalogy.org
Sponsored by: http://www.iminteractive.net Internet Solutions, web host & more!