develooper Front page | perl.beginners | Postings from January 2002

module directory problem

Thread Next
From:
Yeung Siu
Date:
January 18, 2002 05:21
Subject:
module directory problem
Message ID:
20020117224736.61636.qmail@web14606.mail.yahoo.com
Hi all,

I have problem with directory environment. The scripts
are on a NT system using Active Perl v5.6.1. I have
one script at 

foo\test.pl

and use package at

tools\tools.pm


I imported the tools.pm to test.pl during this

# in test.pl script
use lib '../tools';
use TOOLS;


The tools.pm has the following:

# in tools.pm
package TOOLS;
use Cwd;

$dir = cwd();  ### get the path of the current
directory
print "$dir\n";

1;

The problem is that the value of $dir is "foo\" and
not "tools\" even "tools.pm" in the "tools\". This is
a problem since I need to access files with data in
"tools\" from the tools.pm script. Are there anyway to
solve the module import problem? Thanks =D

__________________________________________________
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About