Re: -type error



Norman Elliott wrote:
Hi,
I have just tried writing my first tck/tk program and get some errors.

I am running Mandriva 2006 with tcl-8.4.11-1mdk and tk-8.4.11-1mdk installed.
the program code is :

#!/usr/bin/wish
# I have also tried #!/usr/bin/env wish for the first line
proc launchbrowser {} { exec firefox &; }
proc launchemail {} { exec thunderbird &; }
frame .app -borderwidth 10;
.app configure -background lightblue;
pack .app;
button .app.browser -text "Firefox" -command launchbrowser;
button .app.email -text "Thunderbird" -command launchemail;
pack .app.browser .app.email;

and the errors are :
unknown option "-type"
unknown option "-type"
while executing
". cget -type"
(command bound to event)
and
bad option "index": must be cget or configure
bad option "index": must be cget or configure
while executing
"$menu index active"
(procedure "tk::MenuLeave" line 4)
invoked from within
"tk::MenuLeave . 105 101 0"
(command bound to event)
Can anyone help please?
Norm
Forgot to mention that the error is triggered as soon as the mouse
moves over the menu created by the program.
.


Quantcast