Re: Perl Tk:Scheduler command called subroutine fails to talk to tk widgets
- From: "Andy" <anedza@xxxxxxxxxxxxxxxxxxxxxx>
- Date: 2 Feb 2007 07:20:12 -0800
I've read your reply and tried moving the run subroutine into a
variable, and declaring it and the tk read only text widget before the
creation of the scheduler. The code compiles and runs. But, when the
scheduler tries to parse the code in the command variable, the
following error occurs (buried deep inside of some perl modules the
scheduler itself uses):
Tk::Error: Usage: ->coderef2text(CODEREF) at C:/Perl/site/lib/Tk/
Schedule.pm line 374
Carp::croak at C:/Perl/lib/Carp.pm line 269
B::Deparse::coderef2text at C:/Perl/lib/B/Deparse.pm line 671
Tk::Schedule::AddTime at C:/Perl/site/lib/Tk/Schedule.pm line 374
Tk callback for .schedule.frame.button
Tk::__ANON__ at C:/Perl/site/lib/Tk.pm line 252
Tk::Button::butUp at C:/Perl/site/lib/Tk/Button.pm line 111
<ButtonRelease-1>
(command bound to event)
As I haven't written the scheduler or the other modules it uses, I
have no idea what this error is saying went wrong. But, I suspect it
has to do with something with the command code being treated as plain
text before it is executed in the eval statement within the
shceduler. If so, we seem to be losing the memory references to
variables again.
But, thanks for the suggestion.
.
- Follow-Ups:
- References:
- Re: Perl Tk:Scheduler command called subroutine fails to talk to tk widgets
- From: Dominique Dumont
- Re: Perl Tk:Scheduler command called subroutine fails to talk to tk widgets
- Prev by Date: Re: Perl Tk:Scheduler command called subroutine fails to talk to tk widgets
- Next by Date: Re: Perl Tk:Scheduler command called subroutine fails to talk to tk widgets
- Previous by thread: Re: Perl Tk:Scheduler command called subroutine fails to talk to tk widgets
- Next by thread: Re: Perl Tk:Scheduler command called subroutine fails to talk to tk widgets
- Index(es):