Wow you're good! The problem was that $dest needed "chomp $dest". So your "\n" 
theory was correct.

THANKS!



> From: [EMAIL PROTECTED]
> To: [email protected]
> Date: Wed, 12 Dec 2007 16:15:04 +0100
> Subject: Re: System Calls
> 
> From: Jerry Kassebaum <[EMAIL PROTECTED]>
> > On my Windows XP this line:
> > 
> > `copy $source\\$_ $dest`;
> > 
> > will copy files from c:\whatever\whatever\file.ext to the directory
> > the Perl script is in, but not to $dest. How do I make it copy to
> > $dest? 
> > 
> > FYI, $source="c:\\whatever\\whatever"; so the backslash isn't the problem.
> 
> And $dest is?
> 
> Are you sure the command looks right? Try to add
> 
> print "EXECUTE: copy $source\\$_ $dest\n";
> 
> above that command. I would not be surprised if you found out that 
> the $source actually looked like this:
> 
>       $source="c:\\whatever\\whatever\n";
> 
> Always make sure the variables contain exactly what you think they do 
> and the command looks exactly as you expected!
> 
> In this particular case you should
> 
>       use File::Copy;
> 
> anyway.
> 
> 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
> 
> _______________________________________________
> Perl-Win32-Users mailing list
> [email protected]
> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

_________________________________________________________________
The best games are on Xbox 360.  Click here for a special offer on an Xbox 360 
Console.
http://www.xbox.com/en-US/hardware/wheretobuy/
_______________________________________________
Perl-Win32-Users mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to