On 15 dic, 04:30, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > i am trying out tkinter to make a gui..i want to have a frame with an > embedded file explorer next to a 'open directory' label..i tried out > FileDialog and tkFileDialog methods but they open as pop up dialogs.. > how do i make this packed into the frame the way button and other > widgets can be packed? i am a newbie to tkinter..
Try using Tix, a Tkinter extension included in the Python library. It provides a DirList widget: <code> import Tix class App: def __init__(self, master): frame = Tix.Frame(master) frame.pack() dirlist = Tix.DirList(frame, value=r"f:\download\temp", command=self.showdir) dirlist.pack(fill="x") button = Tix.Button(frame, text="Close", command=frame.quit) button.pack() def showdir(self, directory): print "user selected", directory root = Tix.Tk() app = App(root) root.mainloop() </code> -- Gabriel Genellina -- http://mail.python.org/mailman/listinfo/python-list