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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Regarding the command [gets stdin]

Status
Not open for further replies.

6839470

Programmer
Mar 7, 2004
45
US
hi everyone,
This is regarding the command in tcl
when i am trying to use the above command my console hangs, can anyone suggest me a solution or solve the problem ...if below shown syntax isn't correct...please suggest corrections with an example.

puts -nonewline "Enter Name: "
set sumanth [gets stdin]
set fileid [open $sumanth w+]
puts $fileid "hi"
close $fileid

Thanks
ss
 
It's hard to say from just the information you provided but are you, by chance, using the "wish" shell rather than the "tclsh" shell?

Bob Rashkin
rrashkin@csc.com
 
Ya it is a tcl console.......and i am typing the exact code what I have posted here. So any solutions??...
 
Instead of
Code:
set sumanth [gets stdin]
try
Code:
gets stdin sumanth


Bob Rashkin
rrashkin@csc.com
 
I already did that.......and i don't think that as well serve my purpose
anyways
 
Does anyone know about the sound recognition software implemented using tcl/tk
do let me know abt this asap
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top