[Tkinter-discuss] Easy way to get a file explorer?
alexnbryan at gmail.com
Thu Jun 12 21:36:33 CEST 2008
Thanks, this is exactly what I am looking for, but I can't find much useful
documentation on it. So I want to have it give me a string of the path of
the file they selected, which seems simple, but I am having issues. for
path = tkFileDialog.askopenfile()
it prints this:
<open file 'C:/Documents and Settings/Alex/My Documents/My
Music/101-u2-instant_karma.mp3', mode 'r' at 0x00C3EE78>
but all I want is the actual path. So how can I do that?
Kevin Walzer-5 wrote:
> Alexnb wrote:
>> Okay, so in the small app I am creating I want to have a button that
>> activates a file explorer and then once the user selects a file I want to
>> able to get the path of that file. Is there a way to do this without
>> into serious detail? and if not could someone point me in the right
>> direction? I am open to about anything. Thanks.
> tkFileDialog is what you're looking for.
> Kevin Walzer
> Code by Kevin
> Tkinter-discuss mailing list
> Tkinter-discuss at python.org
View this message in context: http://www.nabble.com/Easy-way-to-get-a-file-explorer--tp17806393p17808068.html
Sent from the Python - tkinter-discuss mailing list archive at Nabble.com.
More information about the Tkinter-discuss