In my tcl file, i need to ask a filename to my user ?
I try tkFDialog :
set filename [tkFDialog \
-title "Load Database" \
-initialdir $dirproj \
-filetypes {{{Mesh files} {.mail}}}]
but when executing, Gid is blocked, and no window appears.
A second question :
It is possible to ask question and to read answer on command line in tcl
file ?
Thanks
________________________________________________________________
Guy HUBERT Mailto:hubert at deltacad.fr
Tel direct : +33 (0)3 44 23 52 99 mobile: 06 76 80 03 42
DeltaCAD
Centre de Transfert - 66 Avenue de Landshut
60200 COMPIEGNE (FRANCE)
Tel : +33 (0)3 44 23 46 54 - Fax : +33 (0)3 44 23 46 31
Web : http://www.deltacad.fr
[GiDlist] How to ask something to user in Tcl
Moderator: GiD Team
[GiDlist] How to ask something to user in Tcl
the procedure tkFDialog is moved to a namespace in the last tcl/tk releases.
Best, can use the GiD tcl procedure Browser-ramR.
For example, to open a file with *.txt extension, use:
set filename [Browser-ramR file read .gid "Read text file" {} {{{text file} {.txt}} {{All files} {.*}}} ]
if {$filename == ""} {
return
}
To ask a question or show a message in the "lower message bar", can put your own text with:
::GidUtils::SetWarnLine $text
but to return a answer from the GiD command line to a tcl user procedure, instead to
internally process by GiD, it's not easy.
Enrique Escolano
----- Original Message -----
From: "Guy HUBERT" hubert at deltacad.fr
To: gidlist at gatxan.cimne.upc.es
Sent: Friday, October 10, 2003 12:45 PM
Subject: [GiDlist] How to ask something to user in Tcl
In my tcl file, i need to ask a filename to my user ?
I try tkFDialog :
set filename [tkFDialog \
-title "Load Database" \
-initialdir $dirproj \
-filetypes {{{Mesh files} {.mail}}}]
but when executing, Gid is blocked, and no window appears.
A second question :
It is possible to ask question and to read answer on command line in tcl
file ?
Thanks
________________________________________________________________
Guy HUBERT Mailto:hubert at deltacad.fr
Tel direct : +33 (0)3 44 23 52 99 mobile: 06 76 80 03 42
DeltaCAD
Centre de Transfert - 66 Avenue de Landshut
60200 COMPIEGNE (FRANCE)
Tel : +33 (0)3 44 23 46 54 - Fax : +33 (0)3 44 23 46 31
Web : http://www.deltacad.fr
_______________________________________________
GiDlist mailing list
GiDlist at gid.cimne.upc.es
http://gid.cimne.upc.es/mailman/listinfo/gidlist
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20031010/1291178d/attachment.htm
Best, can use the GiD tcl procedure Browser-ramR.
For example, to open a file with *.txt extension, use:
set filename [Browser-ramR file read .gid "Read text file" {} {{{text file} {.txt}} {{All files} {.*}}} ]
if {$filename == ""} {
return
}
To ask a question or show a message in the "lower message bar", can put your own text with:
::GidUtils::SetWarnLine $text
but to return a answer from the GiD command line to a tcl user procedure, instead to
internally process by GiD, it's not easy.
Enrique Escolano
----- Original Message -----
From: "Guy HUBERT" hubert at deltacad.fr
To: gidlist at gatxan.cimne.upc.es
Sent: Friday, October 10, 2003 12:45 PM
Subject: [GiDlist] How to ask something to user in Tcl
In my tcl file, i need to ask a filename to my user ?
I try tkFDialog :
set filename [tkFDialog \
-title "Load Database" \
-initialdir $dirproj \
-filetypes {{{Mesh files} {.mail}}}]
but when executing, Gid is blocked, and no window appears.
A second question :
It is possible to ask question and to read answer on command line in tcl
file ?
Thanks
________________________________________________________________
Guy HUBERT Mailto:hubert at deltacad.fr
Tel direct : +33 (0)3 44 23 52 99 mobile: 06 76 80 03 42
DeltaCAD
Centre de Transfert - 66 Avenue de Landshut
60200 COMPIEGNE (FRANCE)
Tel : +33 (0)3 44 23 46 54 - Fax : +33 (0)3 44 23 46 31
Web : http://www.deltacad.fr
_______________________________________________
GiDlist mailing list
GiDlist at gid.cimne.upc.es
http://gid.cimne.upc.es/mailman/listinfo/gidlist
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20031010/1291178d/attachment.htm