Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

invalid command name "button" !?!?!

353 views
Skip to first unread message

Sami-Jaakko Tikka

unread,
Aug 27, 1993, 6:28:53 AM8/27/93
to
I have just installed Tcl 7 and Tk 3.3. I wrote a program, or actually
wrote Tcl_AppInit routine that creates a couple of tcl procedures and
sources one tcl script file. I then linked it with -ltcl -ltk -lX11 -lm
and ran it. The program responds:

laphroaig% ./tcl_ui -display tahma:0 master
invalid command name: "button"
while executing
"button .new -padx 10 -pady 5 -text New -command new_conf"
(procedure "main_buttons" line 2)
invoked from within
"main_buttons"
invoked from within
"if {$master} {
main_buttons
}"
(file "ui.tcl" line 138)
invoked from within
"source ui.tcl"
zsh: 5438 exit 1 ./tcl_ui -display tahma:0 master
laphroaig%

I am not very familiar with Tcl & Tk (yet) so I have no clue where to start
looking for the problem. Isn't button a command that should always be
available? Or should I make some obscure call that enables me to use
button, listbox, scrollbar, etc..

--
inet: Sami....@hut.fi, X.400: C=fi;ADMD=fumail;O=hut;S=Tikka;G=Sami
HUT/IIA; I don't speak for my employer. Finger me for my PGP key.

Karl Lehenbauer

unread,
Sep 2, 1993, 9:03:48 AM9/2/93
to
In article <sti-2708...@tko-labra-11.cs.hut.fi> s...@cs.hut.fi (Sami-Jaakko Tikka) writes:
>I have just installed Tcl 7 and Tk 3.3. I wrote a program, or actually
>wrote Tcl_AppInit routine that creates a couple of tcl procedures and
>sources one tcl script file. I then linked it with -ltcl -ltk -lX11 -lm
>and ran it. The program responds:
>invalid command name: "button"

You still need to do everything Wish's Tcl_AppInit does, such as:

main = Tk_MainWindow(interp);

...and...

if (Tk_Init(interp) == TCL_ERROR) {
return TCL_ERROR;
}

--
-- Email in...@NeoSoft.com for info on getting interactive Internet access.
"The road untravelled is the road that can be endlessly speculated about."

0 new messages