Hi!
Ein Kollege hat ziemlich Streß und so hat er mich gebeten ihn ein bisschen auszuhelfen in Tcl/Tk. Und kaum will ich was machen taucht schon gleich ein Problem auf, wie solls auch anders sein.
Er weiß auch nicht worans liegt.
Ich möchte ein dateentry, wie das beispiel in Widgets zeigt, einbinden:
package require Iwidgets 3.0
Demo script for dateentry class
proc returnCmd {} {
puts [.de get]
}
iwidgets::dateentry .de -labeltext "Date:" -command returnCmd
pack .de -fill x -expand yes -padx 10 -pady 10
In der Shell geht das auch, aber wenn ich das in das Programm einbinde kommt folgender Fehler, dieser aber auch erst, wenn ich den Kalender anklicke:
Error: class "iwidgets::Dateentry" already exists.
und bei Stack Trace folgende Fehlerausgabe:
class "iwidgets::Dateentry" already exists
while executing
"class iwidgets::Dateentry {
inherit iwidgets::Datefield
constructor {args} {}
itk_option define -grab grab Grab "global"
itk_opt..."
(file "C:/Programs/TclPro1.4/lib/iwidgets3.0.1/scripts/dateentry.itk" line 49)
invoked from within
"source C:/Programs/TclPro1.4/lib/iwidgets3.0.1/scripts/dateentry.itk"
("uplevel" body line 1)
invoked from within
"uplevel #0 $auto_index($name)"
(procedure "::auto_load" line 13)
invoked from within
"grab -global $itk_component(popup)"
(object "::.box.middle.end.up.date" method "::iwidgets::Dateentry::_popup" body line 80)
invoked from within
"::.box.middle.end.up.date _popup"
(in namespace inscope "::iwidgets::Dateentry" script line 1)
invoked from within
"namespace inscope ::iwidgets::Dateentry "
(command bound to event)
Mhh.. ich hoffe das hier im Forum auch ein Tcl/Tk - Profi sitzt ;)
tOM