M
mmasroorali
Hello All,
I want to keep some system parameters to be used by several
subroutines. So, I write in
ptestdefs.pm
#!/usr/bin/perl
# $Header:$
# $Log:$
use strict;
use warnings;
use Env;
# Column width for taskbar p columns
my $pw = "2.0mm";
Now in ptest.pl, I write
#!/usr/bin/perl
use strict;
use warnings;
use ptestdefs;
print "$pw\n";
When ptest.pl is executed, all I get is,
Global symbol "$pw" requires explicit package name at ./ptest.pl line
8.
Execution of ./ptest.pl aborted due to compilation errors.
Could you please tell me how I can define $pw in ptestdefs.pm to be
used in several other pm files?
Regards.
I want to keep some system parameters to be used by several
subroutines. So, I write in
ptestdefs.pm
#!/usr/bin/perl
# $Header:$
# $Log:$
use strict;
use warnings;
use Env;
# Column width for taskbar p columns
my $pw = "2.0mm";
Now in ptest.pl, I write
#!/usr/bin/perl
use strict;
use warnings;
use ptestdefs;
print "$pw\n";
When ptest.pl is executed, all I get is,
Global symbol "$pw" requires explicit package name at ./ptest.pl line
8.
Execution of ./ptest.pl aborted due to compilation errors.
Could you please tell me how I can define $pw in ptestdefs.pm to be
used in several other pm files?
Regards.