|
| Hi Folks,
When I run any od the demo scripts for "TableMartix" (say
embeddedWindows.pl) I get the following error:
===============
Had to create Tk::XlibVtab unexpectedly at C:/PRG/Perl/lib/DynaLoader.pm
line 252.
Use of uninitialized value in subroutine entry at
C:/PRG/Perl/lib/DynaLoader.pm line
1ce37a8 is not a hash at C:/PRG/Perl/lib/Tk/Widget.pm line 190.
This application has requested the Runtime to terminate it in an unusual
way.
Please contact the application's support team for more information.
=====================
I am running
This is perl, v5.8.8 built for MSWin32-x86-multi-thread
(with 18 registered patches, see perl -V for more detail)
Copyright 1987-2007, Larry Wall
Binary build 822 [280952] provided by ActiveState http://www.ActiveState.com
Built Jul 31 2007 19:34:48
==============================
here is the script
=============================
##########
### Demo of using embedded windows in TableMatrix
### This works well, but can be slow for very large tables with many
### windows.
###
### See edit_styles.pl for an alternative that is faster for larger
### tables
use Tk;
use Tk::BrowseEntry;
use Tk::TableMatrix;
use Data::Dumper qw( DumperX);
my $top = MainWindow->new;
my $arrayVar = {};
my $radio = '';
foreach my $row (0..20){
foreach my $col (0..10){
$arrayVar->{"$row,$col"} = "r$row, c$col";
}
}
my $t = $top->Scrolled('TableMatrix',
-rows => 21,
-cols => 11,
-width => 6,
-height => 20,
-rowheight => -25, ####
-titlerows => 1,
-titlecols => 1,
-variable => $arrayVar,
-selectmode => 'extended',
-resizeborders => 'both',
-titlerows => 1,
-titlecols => 1,
-bg => 'white',
# -state => 'disabled'
# -colseparator => "\t",
# -rowseparator => "\n"
);
$t->tagConfigure('active', -bg => 'gray90', -relief => 'sunken');
$t->tagConfigure( 'title', -bg => 'gray85', -fg => 'black', -relief =>
'sunken');
################ Put in some embedded windows ################
######### CheckButton
my $l1 = $top->Checkbutton(-text => 'CheckButton');
my $l2 = $top->Checkbutton(-text => 'CheckButton2');
$t->windowConfigure("3,3", -sticky => 's', -window => $l1);
#$t->windowConfigure("3,4", -sticky => 's', -window => $l2);
############### BrowseEntry
my $c = $top->BrowseEntry(-label => "Month:");
$c->insert("end", "January");
$c->insert("end", "February");
$c->insert("end", "March");
$c->insert("end", "April");
$c->insert("end", "May");
$c->insert("end", "June");
$c->insert("end", "July");
$c->insert("end", "August");
$c->insert("end", "September");
$c->insert("end", "October");
$c->insert("end", "November");
$c->insert("end", "December");
$t->windowConfigure("2,2", -sticky => 's', -window => $c);
################## Radiobutton
my @RB = ();
for my $i (0 .. 10)
{
$RB[$i] = $top->Radiobutton( #-text => '',
-bg => 'white',
-relief => 'flat',
#-activebackground => 'white',
-variable => \$radio,
-value => $i
);
my $j = $i + 4;
$t->windowConfigure("$j,4", -sticky => 's', -window => $RB[$i]);
}
# Leave enough room for the windows
$t->colWidth(2,20);
$t->colWidth(3,20);
$t->colWidth(4,10);
$t->pack(-expand => 1, -fill => 'both');
Tk::MainLoop;
==============
Regards,
-Sean
|
|