[Help] Warcraft InstallPath reg query

Discussion in 'Blizzard Games Help' started by nnieheayp, Apr 15, 2012.

  1. nnieheayp Member

    I want to delete some hacking file with batch file but i failed. Please someone fix for me. really i need it :(
    Code:
    @echo OFF
    
    setlocal ENABLEEXTENSIONS
    set KEY_NAME="HKEY_CURRENT_USER\SOFTWARE\Blizzard Entertainment\Warcraft III"
    set VALUE_NAME=InstallPath
    
    FOR /F "tokens=3-4" %%A IN ('REG QUERY %KEY_NAME% /v %VALUE_NAME% 2^>nul') DO (
    set ValueA=%%A
    set ValueB=%%B
    )
    
    if defined ValueA (
    @echo Value Value = %ValueA% %ValueB%
    del @echo"%ValueA% %ValueB%test.txt"
    ) else (
    @echo %KEY_NAME%\%VALUE_NAME% not found.
    )
    pause
    

Share This Page