PC Review


Reply
Thread Tools Rate Thread

Copy IE Favorites Dir using batch/cmd to mapped drive?

 
 
Mike
Guest
Posts: n/a
 
      7th Oct 2004
I need to create a .bat or .cmd file that users can run to
copy their IE favorites to a mapped network drive. All
attempts thus far are not successfult. From the command
line I can run the script and it works just fine, but if I
careate a .txt, rename it with a .bat or .cmd, it does not
work. I receive an error message stating that "The system
cannot find the path specified.
File not found - Favorites". Can someone help me with
this please ASAP?
Thanks,
Mike V.
 
Reply With Quote
 
 
 
 
Heath
Guest
Posts: n/a
 
      7th Oct 2004
Try this


@echo off
cd /d c:\
cd %userprofile%
xcopy favorites /h /s /y (driveath)
cls
exit

>-----Original Message-----
>I need to create a .bat or .cmd file that users can run

to
>copy their IE favorites to a mapped network drive. All
>attempts thus far are not successfult. From the command
>line I can run the script and it works just fine, but if

I
>careate a .txt, rename it with a .bat or .cmd, it does

not
>work. I receive an error message stating that "The

system
>cannot find the path specified.
>File not found - Favorites". Can someone help me with
>this please ASAP?
>Thanks,
>Mike V.
>.
>

 
Reply With Quote
 
Paul R. Sadowski [MVP]
Guest
Posts: n/a
 
      7th Oct 2004

"Mike" <(E-Mail Removed)> wrote in message
news:40d101c4ac84$6e89ed50$(E-Mail Removed)...
>I need to create a .bat or .cmd file that users can run to
> copy their IE favorites to a mapped network drive. All
> attempts thus far are not successfult. From the command
> line I can run the script and it works just fine, but if I
> careate a .txt, rename it with a .bat or .cmd, it does not
> work. I receive an error message stating that "The system
> cannot find the path specified.
> File not found - Favorites". Can someone help me with
> this please ASAP?


Did you double quote the path?
xcopy "%USERPROFILE%\Favorites" \\server\backups\whatever /s /e /y /i /c

The /c switch tells xcopy to continue even if there is an error. I like to
use it for backups but it's optional and up to you.

Now it is possible that there's a bad filename in there. I've seen it happen
on my own machine. The /C switch will allow the copy to continue anyway.

You really should post your code if this doesn't help you.


 
Reply With Quote
 
Mike
Guest
Posts: n/a
 
      7th Oct 2004
That was exactly what I needed! I didn't have the system
variable right. Thanks.

>-----Original Message-----
>
>"Mike" <(E-Mail Removed)> wrote in

message
>news:40d101c4ac84$6e89ed50$(E-Mail Removed)...
>>I need to create a .bat or .cmd file that users can run

to
>> copy their IE favorites to a mapped network drive. All
>> attempts thus far are not successfult. From the command
>> line I can run the script and it works just fine, but

if I
>> careate a .txt, rename it with a .bat or .cmd, it does

not
>> work. I receive an error message stating that "The

system
>> cannot find the path specified.
>> File not found - Favorites". Can someone help me with
>> this please ASAP?

>
>Did you double quote the path?
>xcopy "%USERPROFILE%\Favorites"

\\server\backups\whatever /s /e /y /i /c
>
>The /c switch tells xcopy to continue even if there is an

error. I like to
>use it for backups but it's optional and up to you.
>
>Now it is possible that there's a bad filename in there.

I've seen it happen
>on my own machine. The /C switch will allow the copy to

continue anyway.
>
>You really should post your code if this doesn't help

you.
>
>
>.


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Apologies if incorrect group - Mapped drive rename from batch error Richhall Windows XP General 13 5th Feb 2008 03:16 PM
batch file does copy to mapped drive if scheduled RK Microsoft Windows 2000 2 21st Aug 2004 03:09 PM
Batch File to Reconnect to Mapped Drive EER Microsoft Windows 2000 CMD Promt 3 25th May 2004 07:21 PM
UNC File copy MUCH FASTER than mapped UNC drive copy? NTNEWS Microsoft Windows 2000 0 17th Sep 2003 07:01 AM
UNC File copy MUCH FASTER than mapped UNC drive copy? NTNEWS Microsoft Windows 2000 File System 0 17th Sep 2003 07:01 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:21 AM.