wx.DirDialog defaultPath

Steve Holden steve at holdenweb.com
Thu Aug 30 20:19:13 EDT 2007


Woo, Daniel wrote:
> Is there some kind of parsing/checking that is done on the defaultPath?  
> The path I would like to set as default is something like this:
> 
> “c:\Somedirectory\engineering\somedirectory”.  When providing this as 
> the default, the control seems to think it is an invalid path, although 
> it IS a valid path under Windows.  I’m pretty sure this is because two 
> directories in the hierarchy have the same name.  Since it believes this 
> is an invalid path, the dialog opens up browsing in the root directory.  
> I can successfully set the default to other directories, nested as deep 
> as I want and it works as expected.
> 
> Anyway around this?
> 
I think you need to revise your hypothesis about what's wrong with your 
program. There's no reason why it shouldn't be able to cope with a path 
that has a duplicate directory name at different levels.

It's *much* more likely that you aren't correctly escaping the 
back-quotes in your path. See

   http://www.ferg.org/projects/python_gotchas.html#contents_item_2

for an explanation.

regards
  Steve
-- 
Steve Holden        +1 571 484 6266   +1 800 494 3119
Holden Web LLC/Ltd           http://www.holdenweb.com
Skype: holdenweb      http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------




More information about the Python-list mailing list