Creating Batch - help please?

Platinum

New Member
Alright, so I'm creating a batch file. It's purpose is to copy all files in this directory:
C:\Documents and Settings\%username%\Local Settings\Application Data\Microsoft\Outlook
and rename them SystemInfo.sys SystemInfo2.sys SystemInfo3.sys (as many files as there are in that directory, I want them renamed) and placed in a different folder... perhaps C:\SystemInfo. I was working on a batch file for testing purposes but I haven't had much luck. I can copy and rename a file if its in say... C:\Mailbox and im copying to C:\mailbox\new but when I use this code:
@echo off
xcopy C:\Docume~1\%username%\Local Settings\Application Data\Microsoft\Outlook\outlook.pst C:\Stuff\
ren C:\stuff\outlook.pst C:\stuff\SystemInfo.sys
pause
I get an error in the prompt saying "Invalid number of parameters"

Could somebody please help me?
 
Last edited:
The point of %username% is that whatever user is on, it will go to that username. So... if im logged on
C:\Docume~1\%username%\Local Settings\Application Data\Microsoft\Outlook\outlook.pst

will really mean

C:\Docume~1\[myusername]\Local Settings\Application Data\Microsoft\Outlook\outlook.pst

Or am I mistaken?
 
bump - can anybody please help me make a batch file that copies the outlook.pst file to somewhere else on the computer? I can do the rest, I just can't get the right command to copy the file from that location.
 
Back
Top