Windows 2000/2003 Batch file variables / wildcards - TechRepublic
Question
March 21, 2007 at 11:05 AM
cburnham

Windows 2000/2003 Batch file variables / wildcards

by cburnham . Updated 19 years, 3 months ago

I am writing a batch file to copy a *.pst file from user machines to the server upon user logoff.

The location of the *.pst file will be the same for each profile of each user on the computer. I don’t know how to put wildcards or variables in. I don’t want to have to write a batch file for each user – I want one file that works for all.

Here is what I have so far. Where I have put are the places where I need wildcards/variables:

@ECHO off
xcopy /e /v /y \\\c$\documents and settings\\local settings\application data\microsoft\outlook\ \\serverv\users\\outlook_backup

On some of my machines I have more than one profile with a *.pst file to be copied. I want it to basically check all profiles and copy them

What are the variables or wildcards I could use so that I can write one batch file that would work for all users? The file will be placed in domain policy/user configuration/log off on my 2000 or 2003 servers.

Thanks, everyone –

Cathy
Maine

This discussion is locked

All Comments