It would help debugging if we could see the offending code.
I have seen bugs like this when (1) Tk is not installed properly
or (2) the appropriate
use statements have not
been included:
use Tk;
use Tk::Text; # not sure this is needed, but can't hurt
-Mark