Python version: 2.7 Tk version: 8.5
Refer to my previous question how to add the selected files from dialog window to a dictionary?
I am trying to select 50
I think I can see where the issue is. I have done a little debugging and found that the data type returned into filez is a unicode string (where you seem to be expecting a list or tuple).
You will need to convert this before your loop. If none of your file names contain spaces this should just be a simple matter of:
file_list = files.split()
However, if this is not the case then the above will not work and and filenames that contain spaces with be enclosed with curly braces {}.
This may actually be a bug according to this page. However, a work around is also suggested to convert the string to a tuple:
file_list= master.tk.splitlist(filez)
Hope this helps.