Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

long file names : file names with spaces

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
a file browser

here's the code

proc insert { dir } {
set lista [open "|ls $dir"]
fconfigure $lista -blocking false
fileevent $lista readable [list ok $lista]
vwait ::DONE
close $lista
}

proc ok { f } {

set status [catch { gets $f line } result]
.esquerda.scrollbox.first insert end "$line"
}

the problem is that when i have a directory named like this :

\dir ec tory

the name apears correctly in the list and it is recognized as a directory but subdirectories or files inside "\dir ec tory" do not apear in the list box.

i've tried regsub to replace "\dir ec tory" with
"\dir\ ec\ tory

but it doesn't work

thanks for your time, bye :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top