AddPst.exe tool.

D

Dave

When using the addpst.exe file in a vbscript below. The path to the moved pst
file in the Outlook data files only places the first word if their are
spaces.

For example:
If the new path is c:\documents and settings\my profile
the path in the data files path will be c:\documents

Everything after the first space will not enter. I have tried variations of
quotations etc but cant seem to get past this...

Thanks

________________________

objshell.Run "c:\lansd\addPst.exe -p autoprofile -t c:\documents and
settings\my Profile -d PSTFile -f u ",0,"TRUE"
 
B

Brian Tillman [MVP - Outlook]

When using the addpst.exe file in a vbscript below. The path to the moved
pst
file in the Outlook data files only places the first word if their are
spaces.

For example:
If the new path is c:\documents and settings\my profile
the path in the data files path will be c:\documents

You need to quote "C:\Documents and Settings\user". Strings containing spaces
must be enclosed in quotes. I don't know how scripts work, but, assuming that
two quotes within a string means one quote gets passed in, then something
like:

objshell.Run "C:\lansd\addPst.exe -p autoprofile -t ""C:\Documents and
Settings\My Profile"" -d PSTFile -f u", 0, "TRUE"

If it uses Unix-like syntax, then perhaps it's

objshell.Run "C:\\lansd\\addPst.exe -p autoprofile -t \"C:\\Documents and
Settings\\My Profile\" -d PSTFile -f u", 0, "TRUE"
 
R

Roady [MVP]

Your first assumption was correct :)

Of course don't forget above your code'
Set objShell = CreateObject("WScript.Shell")
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top