Thanks for the quick response, using the print command I saw the error
of my way !!! 

I had a space in $node.

Thanks again for the help !!!

---Larry

-----Original Message-----
From: Jenda Krynicky [mailto:Jenda@;Krynicky.cz] 
Sent: Monday, November 04, 2002 3:41 PM
To: [EMAIL PROTECTED]
Subject: Re: Connecting to a drive

From: "Larry Sandwick" <[EMAIL PROTECTED]>
> I am trying to write a Perl script that will replicate a directory on
> one computer to another. All of the computers are running XP. I do
> have administrative privileges.
> 
> The problem is when I run the line below I never get connected to the
> computer from within the scripted.
> 
>  system "net use m: \\$node\\c\$ <file:///\\$node\c\$>  user:/username
> password";

Try to print the command instead of executing it. You'll see the 
problem.

You may also want to try

        use Win32::FileOp; # http://Jenda.Krynicky.cz/#Win32::FileOp

        Map 'M:' => "\\\\$node\\c\$", 
                {user => $username, passwd => $password, overwrite =>
1};

Jenda
===== [EMAIL PROTECTED] === http://Jenda.Krynicky.cz =====
When it comes to wine, women and song, wizards are allowed 
to get drunk and croon as much as they like.
        -- Terry Pratchett in Sourcery


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to