Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- REM ***This batch file will automatically run SCANPST on every PST file in the
- REM ***directory specified by PST_FILE_MASK.
- set SCANPST_PATH="C:\Program Files (x86)\Microsoft Office\root\Office16\SCANPST.EXE"
- set PST_FILE_MASK="D:\Users\josh\Documents\My Mail\*.pst"
- REM *** CD into in the directory that contains the launched batch file...
- echo CDing into "%~dp0"
- pushd "%~dp0"
- for %%i in (%PST_FILE_MASK%) do (
- REM Add an N to the end of the following line of you don't want backup files
- :loop
- echo checking files %SCANPST_PATH% "%%i" No backup for repair
- cscanpst.exe %SCANPST_PATH% "%%i" N
- echo Finished checking files %SCANPST_PATH% "%%i"
- if errorlevel 3 goto exit
- if errorlevel 1 goto loop
- :exit
- ECHO %SCANPST_PATH% "%%i" File scanned clean!
- )
- :done
- @echo Log:
- @type cscanpst.log
- @pause
Add Comment
Please, Sign In to add comment