Hi chungley2000,
I did a bit more poking around with Config and found the things I was looking for with code like this:
for ( keys %Config ) { if ( defined $Config{$_} ) { if ( $Config{$_} =~ m%/x86_64-linux-gnu/% ) { say "$_ matched: $Config{$_}"; } }
Where the module data will go is certainly system-dependent. What I did to suss out where perl was looking for modules was type
$ perl -le 'print for @INC', and then I paid attention to where cpan was creating files such as DBI.pm . I've reformatted what you had. For example, I deleted whitespace between the module name and the semi-colon. Many of those had wrapped around and gotten newlines where they shouldn't be. And whatever you have needs to be broken down into chunks:
$ ./7.tk.pl version=5.26.1, archname=x86_64-linux-gnu-thread-multi all modules loaded without error Use of uninitialized value $update in concatenation (.) or string at . +/7.tk.pl line 52. return is made it this far without error $ cat 7.tk.pl #!/usr/bin/perl -w use 5.011; #***************************************************************** # Set environment #----------------------------------------------------------------- use Config; # gets the version and directory architecture - BEGIN { my $basedir = '/proj/pdkfc8/tools/perl'; my $version = $Config{'version'}; # perl version my $archname = $Config{'archname'}; # os architecture print("version=$version, archname=$archname\n\n"); push @INC, "$basedir/lib/perl5/site_perl/$version/$archname"; push @INC, "$basedir/lib/perl5/site_perl/$version"; push @INC, "$basedir/lib/site_perl/$version/$archname"; # at botto +m of array } use DBI; # database module use File::Basename; # basepath module use Tk; # TK gui module use Tk::Text; # TK text widget use Tk::TableMatrix; # used in $showSelection to show query resul use Tk::BrowseEntry; # used in $MakeSelectWIndow for @Choices use Tk::DateEntry; # TK Calendar use Tk::TableMatrix::Spreadsheet; # TK Calendar use Data::Dumper; use Path::Tiny; say "all modules loaded without error"; ## create windows my $return = create_windows(); say "return is $return"; sub create_windows { my $mw1 = new MainWindow; $mw1->title("CMVC File Retriever"); #----------------------------------------------------------------- # Set up two frames: # - $frameTop - contains radio buttons for selecting table. # - $frameBottom - contains button to quit without update. #----------------------------------------------------------------- my $update = undef; my $frameTop = $mw1->Frame( -label => "QUERY Table (Last update as of $update)", -relief => 'groove', -borderwidth => 1 )->pack( -side => 'top', -fill => 'both' ); my $table = "fileview"; # default table (turns radio button on) $frameTop->Radiobutton( -text => "file table", -value => "fileview", -variable => \$table )->pack( -side => 'left' ); return "made it this far without error"; } $
I hope this helps,
In reply to Re^3: Retrieving selections from Tk:TableMatrix
by Aldebaran
in thread Retrieving selections from Tk:TableMatrix
by chungley2000
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |