'''o July 18, 2006''' I'm a tcl/tk newbie. I'm still trying to learn the tcl way of programming which is kind of different to what I'm used to. I'm now working on a function/procedure that would convert '''NUMBERS TO WORDS'''. I'll put the link here as soon as it is done. ---- [[[Wiki formatting rules]]] ---- CAU - Have you seen these : [Bag of number/time spellers] ? Arlie - It looks similar to what I'm planning to work on. ---- '''o August 16, 2006''' Arlie - I tried my hands on [Gadgets] and found it very interesting but I was not successfull in running the shorter version of [Larry Smith]. proc gadget { unused type methods } { set typeproc { set typeproc { upvar @var self @type self $method $args } upvar $var self if { "$method" == "" } { return $self } switch $method { @methods } regsub @var $typeproc $var typeproc proc $var { { method "" } args } $typeproc } regsub @type $typeproc $type typeproc regsub @methods $typeproc $methods typeproc proc $type { var method args } $typeproc } Running the test code I got this output: 1 % number N = 1.5 2 % Array A wrong # args: should be "Array var method args" 3 % List L = {foo bar} 4 % N = [N] * $N 5 % set A(cat) Katze Katze 6 % A names 'wrong # args: should be "Array var method args"' 7 % L += grill 8 % L = [L sort] 9 % puts "[L] has [L length] elements, second is [L @ 1]" {} has elements, second is 10 % 10 % File F = "c:/gadget.tcl" 11 % int i = 1 12 % while {[F >> line]} { > puts [i]:$line > i ++ > } variable "var" already exists 13 % F close 14 % Can anyone help me on this?