batch file to sync outlook.pst


Go Back   Computer Help Articles > Windows XP Customize
User Name
Password
FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 01-05-2006, 06:38 AM
cronish
 
Posts: n/a
Default batch file to sync outlook.pst

Unable to copoy outlook.pst from desktop to laptop over home network. Batch
file doesn't work, and in command line, error message is "The system cannot
find the file specified." The outlook.pst file is not hidden or read-only,
and I can copy it over the network using drag & drop, but for some reason
cannot get it to run from a .bat or .cmd file.


Reply With Quote
  #2  
Old 01-05-2006, 06:38 AM
Shenan Stanley
 
Posts: n/a
Default Re: batch file to sync outlook.pst

cronish wrote:
> Unable to copoy outlook.pst from desktop to laptop over home network.
> Batch file doesn't work, and in command line, error message is "The system
> cannot find the file specified." The outlook.pst file is not hidden or
> read-only, and I can copy it over the network using drag & drop, but for
> some reason cannot get it to run from a .bat or .cmd file.


Hope that email is.. faked.

Yeah - you would have to give more information.

For example..
- Is Outlook open or closed when you are trying to copy it?
- What is the contents of your batch script?
- If it is a scheduled task - what rights does the task have?
- When you run the batch script from the command prompt manually - what
errors do you get?

--
Shenan Stanley
MS-MVP
--
How To Ask Questions The Smart Way
http://www.catb.org/~esr/faqs/smart-questions.html


Reply With Quote
  #3  
Old 01-05-2006, 06:38 AM
cronish
 
Posts: n/a
Default Re: batch file to sync outlook.pst

I guess that was pretty lame, I'm completely new to batch files, took an
online tutorial this morning and a little knowledge is a dangerous thing, I
guess. Anyway, the scripts I tried were all like this:

@echo off
Copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
Data\Microsoft\Outlook\outlook.pst L:

where L: is a "Map Network Drive" location opened directly to the Outlook
folder on the laptop I'm trying to sync with.

I tried both with a batch file and directly with the command line. With the
batch file there is no error message, just no result. With the command line
the error message is always "The system cannot find the file specified."

Outlook is closed on both boxes when I'm doing this, or else I realize the
..pst file would be inaccessible.

I even tried copying from the Outlook folder to another folder I created on
my C: drive with this script...

copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
Data\Microsoft\Outlook\outlook.pst c:\testbackup\outlook.pst

....both with a batch script and with the command line, and got the same
result, "The system cannot find the file specified."



"Shenan Stanley" <newshelper@gmail.com> wrote in message
news:e7myszACGHA.3496@TK2MSFTNGP11.phx.gbl...
> cronish wrote:
>> Unable to copoy outlook.pst from desktop to laptop over home network.
>> Batch file doesn't work, and in command line, error message is "The
>> system cannot find the file specified." The outlook.pst file is not
>> hidden or read-only, and I can copy it over the network using drag &
>> drop, but for some reason cannot get it to run from a .bat or .cmd file.

>
> Hope that email is.. faked.
>
> Yeah - you would have to give more information.
>
> For example..
> - Is Outlook open or closed when you are trying to copy it?
> - What is the contents of your batch script?
> - If it is a scheduled task - what rights does the task have?
> - When you run the batch script from the command prompt manually - what
> errors do you get?
>
> --
> Shenan Stanley
> MS-MVP
> --
> How To Ask Questions The Smart Way
> http://www.catb.org/~esr/faqs/smart-questions.html
>




Reply With Quote
  #4  
Old 01-05-2006, 06:38 AM
billious
 
Posts: n/a
Default Re: batch file to sync outlook.pst

> "Shenan Stanley" <newshelper@gmail.com> wrote in message
> news:e7myszACGHA.3496@TK2MSFTNGP11.phx.gbl...
>> cronish wrote:
>>> Unable to copoy outlook.pst from desktop to laptop over home network.
>>> Batch file doesn't work, and in command line, error message is "The
>>> system cannot find the file specified." The outlook.pst file is not
>>> hidden or read-only, and I can copy it over the network using drag &
>>> drop, but for some reason cannot get it to run from a .bat or .cmd file.

>>
>> Hope that email is.. faked.
>>
>> Yeah - you would have to give more information.
>>
>> For example..
>> - Is Outlook open or closed when you are trying to copy it?
>> - What is the contents of your batch script?
>> - If it is a scheduled task - what rights does the task have?
>> - When you run the batch script from the command prompt manually - what
>> errors do you get?
>>
>> --
>> Shenan Stanley
>> MS-MVP
>> --
>> How To Ask Questions The Smart Way
>> http://www.catb.org/~esr/faqs/smart-questions.html
>>

>



"cronish" <cronish@nyc.rr.com> wrote in message
news:_80rf.15081$Ed.9855@news-wrt-01.rdc-nyc.rr.com...
>I guess that was pretty lame, I'm completely new to batch files, took an
>online tutorial this morning and a little knowledge is a dangerous thing, I
>guess. Anyway, the scripts I tried were all like this:
>
> @echo off
> Copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
> Data\Microsoft\Outlook\outlook.pst L:
>
> where L: is a "Map Network Drive" location opened directly to the Outlook
> folder on the laptop I'm trying to sync with.
>
> I tried both with a batch file and directly with the command line. With
> the batch file there is no error message, just no result. With the command
> line the error message is always "The system cannot find the file
> specified."
>
> Outlook is closed on both boxes when I'm doing this, or else I realize the
> .pst file would be inaccessible.
>
> I even tried copying from the Outlook folder to another folder I created
> on my C: drive with this script...
>
> copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
> Data\Microsoft\Outlook\outlook.pst c:\testbackup\outlook.pst
>
> ...both with a batch script and with the command line, and got the same
> result, "The system cannot find the file specified."
>



Where you have spaces (and some other symbols) in a file or pathname, you
need to enclose the name in double-quotes, otherwise the parser simply
interprets the space as an argument-separator and attempts to locate (in
your case) C:\Documents and Settings\G.D. and copy that to Peters\Local

Try

Copy "C:\Documents and Settings\G.D. Peters\Local Settings\Application
Data\Microsoft\Outlook\outlook.pst" L:

(this is all one line, and will likely be wrapped by your newsreader)

Note that this will copy the file to the current directory on L:, not
L:\Documents......

For batch methods discussion for NT/2K/XP, try alt.msdos.batch.nt

HTH

....Bill


Reply With Quote
  #5  
Old 01-05-2006, 06:38 AM
cronish
 
Posts: n/a
Default Re: batch file to sync outlook.pst

Thank-you, Bill, that was great. It didn't work from a batch file, but it
DID work from the command prompt. Is there any reason the same thing
wouldn't work with a batch file? If not, I'm guessing there is a way to
create a .cmd file that I can store somewhere and run from the command line,
rather than having to type out the entire script every time. Still, I'm on
the right trail, now, thanks so much, and happy holidays.
g.

"billious" <billious_1954@hotmail.com> wrote in message
news:43acabb2$0$21622$a82e2bb9@reader.athenanews.c om...
>> "Shenan Stanley" <newshelper@gmail.com> wrote in message
>> news:e7myszACGHA.3496@TK2MSFTNGP11.phx.gbl...
>>> cronish wrote:
>>>> Unable to copoy outlook.pst from desktop to laptop over home network.
>>>> Batch file doesn't work, and in command line, error message is "The
>>>> system cannot find the file specified." The outlook.pst file is not
>>>> hidden or read-only, and I can copy it over the network using drag &
>>>> drop, but for some reason cannot get it to run from a .bat or .cmd
>>>> file.
>>>
>>> Hope that email is.. faked.
>>>
>>> Yeah - you would have to give more information.
>>>
>>> For example..
>>> - Is Outlook open or closed when you are trying to copy it?
>>> - What is the contents of your batch script?
>>> - If it is a scheduled task - what rights does the task have?
>>> - When you run the batch script from the command prompt manually - what
>>> errors do you get?
>>>
>>> --
>>> Shenan Stanley
>>> MS-MVP
>>> --
>>> How To Ask Questions The Smart Way
>>> http://www.catb.org/~esr/faqs/smart-questions.html
>>>

>>

>
>
> "cronish" <cronish@nyc.rr.com> wrote in message
> news:_80rf.15081$Ed.9855@news-wrt-01.rdc-nyc.rr.com...
>>I guess that was pretty lame, I'm completely new to batch files, took an
>>online tutorial this morning and a little knowledge is a dangerous thing,
>>I guess. Anyway, the scripts I tried were all like this:
>>
>> @echo off
>> Copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
>> Data\Microsoft\Outlook\outlook.pst L:
>>
>> where L: is a "Map Network Drive" location opened directly to the Outlook
>> folder on the laptop I'm trying to sync with.
>>
>> I tried both with a batch file and directly with the command line. With
>> the batch file there is no error message, just no result. With the
>> command line the error message is always "The system cannot find the file
>> specified."
>>
>> Outlook is closed on both boxes when I'm doing this, or else I realize
>> the .pst file would be inaccessible.
>>
>> I even tried copying from the Outlook folder to another folder I created
>> on my C: drive with this script...
>>
>> copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
>> Data\Microsoft\Outlook\outlook.pst c:\testbackup\outlook.pst
>>
>> ...both with a batch script and with the command line, and got the same
>> result, "The system cannot find the file specified."
>>

>
>
> Where you have spaces (and some other symbols) in a file or pathname, you
> need to enclose the name in double-quotes, otherwise the parser simply
> interprets the space as an argument-separator and attempts to locate (in
> your case) C:\Documents and Settings\G.D. and copy that to Peters\Local
>
> Try
>
> Copy "C:\Documents and Settings\G.D. Peters\Local Settings\Application
> Data\Microsoft\Outlook\outlook.pst" L:
>
> (this is all one line, and will likely be wrapped by your newsreader)
>
> Note that this will copy the file to the current directory on L:, not
> L:\Documents......
>
> For batch methods discussion for NT/2K/XP, try alt.msdos.batch.nt
>
> HTH
>
> ...Bill
>
>



Reply With Quote
  #6  
Old 01-05-2006, 06:38 AM
cronish
 
Posts: n/a
Default Re: batch file to sync outlook.pst

I'm not finding any resources for writing cmd scripts. Am I wrong in
guessing I could write a script and call it something.cmd and run it from
the command line, to make that copy without typing the whole script every
time?

"cronish" <cronish@nyc.rr.com> wrote in message
news:qi2rf.15102$Ed.12198@news-wrt-01.rdc-nyc.rr.com...
> Thank-you, Bill, that was great. It didn't work from a batch file, but it
> DID work from the command prompt. Is there any reason the same thing
> wouldn't work with a batch file? If not, I'm guessing there is a way to
> create a .cmd file that I can store somewhere and run from the command
> line, rather than having to type out the entire script every time. Still,
> I'm on the right trail, now, thanks so much, and happy holidays.
> g.
>
> "billious" <billious_1954@hotmail.com> wrote in message
> news:43acabb2$0$21622$a82e2bb9@reader.athenanews.c om...
>>> "Shenan Stanley" <newshelper@gmail.com> wrote in message
>>> news:e7myszACGHA.3496@TK2MSFTNGP11.phx.gbl...
>>>> cronish wrote:
>>>>> Unable to copoy outlook.pst from desktop to laptop over home network.
>>>>> Batch file doesn't work, and in command line, error message is "The
>>>>> system cannot find the file specified." The outlook.pst file is not
>>>>> hidden or read-only, and I can copy it over the network using drag &
>>>>> drop, but for some reason cannot get it to run from a .bat or .cmd
>>>>> file.
>>>>
>>>> Hope that email is.. faked.
>>>>
>>>> Yeah - you would have to give more information.
>>>>
>>>> For example..
>>>> - Is Outlook open or closed when you are trying to copy it?
>>>> - What is the contents of your batch script?
>>>> - If it is a scheduled task - what rights does the task have?
>>>> - When you run the batch script from the command prompt manually - what
>>>> errors do you get?
>>>>
>>>> --
>>>> Shenan Stanley
>>>> MS-MVP
>>>> --
>>>> How To Ask Questions The Smart Way
>>>> http://www.catb.org/~esr/faqs/smart-questions.html
>>>>
>>>

>>
>>
>> "cronish" <cronish@nyc.rr.com> wrote in message
>> news:_80rf.15081$Ed.9855@news-wrt-01.rdc-nyc.rr.com...
>>>I guess that was pretty lame, I'm completely new to batch files, took an
>>>online tutorial this morning and a little knowledge is a dangerous thing,
>>>I guess. Anyway, the scripts I tried were all like this:
>>>
>>> @echo off
>>> Copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
>>> Data\Microsoft\Outlook\outlook.pst L:
>>>
>>> where L: is a "Map Network Drive" location opened directly to the
>>> Outlook folder on the laptop I'm trying to sync with.
>>>
>>> I tried both with a batch file and directly with the command line. With
>>> the batch file there is no error message, just no result. With the
>>> command line the error message is always "The system cannot find the
>>> file specified."
>>>
>>> Outlook is closed on both boxes when I'm doing this, or else I realize
>>> the .pst file would be inaccessible.
>>>
>>> I even tried copying from the Outlook folder to another folder I created
>>> on my C: drive with this script...
>>>
>>> copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
>>> Data\Microsoft\Outlook\outlook.pst c:\testbackup\outlook.pst
>>>
>>> ...both with a batch script and with the command line, and got the same
>>> result, "The system cannot find the file specified."
>>>

>>
>>
>> Where you have spaces (and some other symbols) in a file or pathname, you
>> need to enclose the name in double-quotes, otherwise the parser simply
>> interprets the space as an argument-separator and attempts to locate (in
>> your case) C:\Documents and Settings\G.D. and copy that to Peters\Local
>>
>> Try
>>
>> Copy "C:\Documents and Settings\G.D. Peters\Local Settings\Application
>> Data\Microsoft\Outlook\outlook.pst" L:
>>
>> (this is all one line, and will likely be wrapped by your newsreader)
>>
>> Note that this will copy the file to the current directory on L:, not
>> L:\Documents......
>>
>> For batch methods discussion for NT/2K/XP, try alt.msdos.batch.nt
>>
>> HTH
>>
>> ...Bill
>>
>>

>
>



Reply With Quote
  #7  
Old 01-05-2006, 06:38 AM
cronish
 
Posts: n/a
Default Re: batch file to sync outlook.pst

Okay, I figured it out, thanks for your help, it got me on the right trail.
There was an extra space between "Application" and "Data" that I couldn't
see because of the window wrap. Once I removed it and saved as a .bat file
to the desktop and also as a .cmd file to Windows\System32, both scripts ran
perfectly. Thanks again for your kind replies, much appreciated.
g.


"cronish" <cronish@nyc.rr.com> wrote in message
news:7F2rf.15103$Ed.1379@news-wrt-01.rdc-nyc.rr.com...
> I'm not finding any resources for writing cmd scripts. Am I wrong in
> guessing I could write a script and call it something.cmd and run it from
> the command line, to make that copy without typing the whole script every
> time?
>
> "cronish" <cronish@nyc.rr.com> wrote in message
> news:qi2rf.15102$Ed.12198@news-wrt-01.rdc-nyc.rr.com...
>> Thank-you, Bill, that was great. It didn't work from a batch file, but it
>> DID work from the command prompt. Is there any reason the same thing
>> wouldn't work with a batch file? If not, I'm guessing there is a way to
>> create a .cmd file that I can store somewhere and run from the command
>> line, rather than having to type out the entire script every time. Still,
>> I'm on the right trail, now, thanks so much, and happy holidays.
>> g.
>>
>> "billious" <billious_1954@hotmail.com> wrote in message
>> news:43acabb2$0$21622$a82e2bb9@reader.athenanews.c om...
>>>> "Shenan Stanley" <newshelper@gmail.com> wrote in message
>>>> news:e7myszACGHA.3496@TK2MSFTNGP11.phx.gbl...
>>>>> cronish wrote:
>>>>>> Unable to copoy outlook.pst from desktop to laptop over home network.
>>>>>> Batch file doesn't work, and in command line, error message is "The
>>>>>> system cannot find the file specified." The outlook.pst file is not
>>>>>> hidden or read-only, and I can copy it over the network using drag &
>>>>>> drop, but for some reason cannot get it to run from a .bat or .cmd
>>>>>> file.
>>>>>
>>>>> Hope that email is.. faked.
>>>>>
>>>>> Yeah - you would have to give more information.
>>>>>
>>>>> For example..
>>>>> - Is Outlook open or closed when you are trying to copy it?
>>>>> - What is the contents of your batch script?
>>>>> - If it is a scheduled task - what rights does the task have?
>>>>> - When you run the batch script from the command prompt manually -
>>>>> what
>>>>> errors do you get?
>>>>>
>>>>> --
>>>>> Shenan Stanley
>>>>> MS-MVP
>>>>> --
>>>>> How To Ask Questions The Smart Way
>>>>> http://www.catb.org/~esr/faqs/smart-questions.html
>>>>>
>>>>
>>>
>>>
>>> "cronish" <cronish@nyc.rr.com> wrote in message
>>> news:_80rf.15081$Ed.9855@news-wrt-01.rdc-nyc.rr.com...
>>>>I guess that was pretty lame, I'm completely new to batch files, took an
>>>>online tutorial this morning and a little knowledge is a dangerous
>>>>thing, I guess. Anyway, the scripts I tried were all like this:
>>>>
>>>> @echo off
>>>> Copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
>>>> Data\Microsoft\Outlook\outlook.pst L:
>>>>
>>>> where L: is a "Map Network Drive" location opened directly to the
>>>> Outlook folder on the laptop I'm trying to sync with.
>>>>
>>>> I tried both with a batch file and directly with the command line. With
>>>> the batch file there is no error message, just no result. With the
>>>> command line the error message is always "The system cannot find the
>>>> file specified."
>>>>
>>>> Outlook is closed on both boxes when I'm doing this, or else I realize
>>>> the .pst file would be inaccessible.
>>>>
>>>> I even tried copying from the Outlook folder to another folder I
>>>> created on my C: drive with this script...
>>>>
>>>> copy C:\Documents and Settings\G.D. Peters\Local Settings\Application
>>>> Data\Microsoft\Outlook\outlook.pst c:\testbackup\outlook.pst
>>>>
>>>> ...both with a batch script and with the command line, and got the same
>>>> result, "The system cannot find the file specified."
>>>>
>>>
>>>
>>> Where you have spaces (and some other symbols) in a file or pathname,
>>> you need to enclose the name in double-quotes, otherwise the parser
>>> simply interprets the space as an argument-separator and attempts to
>>> locate (in your case) C:\Documents and Settings\G.D. and copy that to
>>> Peters\Local
>>>
>>> Try
>>>
>>> Copy "C:\Documents and Settings\G.D. Peters\Local Settings\Application
>>> Data\Microsoft\Outlook\outlook.pst" L:
>>>
>>> (this is all one line, and will likely be wrapped by your newsreader)
>>>
>>> Note that this will copy the file to the current directory on L:, not
>>> L:\Documents......
>>>
>>> For batch methods discussion for NT/2K/XP, try alt.msdos.batch.nt
>>>
>>> HTH
>>>
>>> ...Bill
>>>
>>>

>>
>>

>
>



Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Trouble with old SUS client Remy G. Windows Update 2 01-05-2006 05:20 PM
Hijack problem Tom B. Windows XP Security Admin 7 01-05-2006 05:44 AM
Need help fixing virus omi Windows XP Security Admin 6 01-05-2006 05:44 AM
EGroup.IEAccess.C (dialer) dtcar Windows XP Help and Support 22 01-05-2006 02:41 AM
USB Mass Storage Device - This device cannot start. (Code 10) lobo201 Windows XP Hardware 11 01-05-2006 02:15 AM


All times are GMT. The time now is 05:48 AM.


Powered by vBulletin Version 3.5.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd. SEO by vBSEO 2.3.2 © 2005, Crawlability, Inc.

batch file to sync outlook.pst