Scan Text File for Registry Entries

@echo off
setlocal enabledelayedexpansion
set count=1
for /f “delims=” %%a in (data.txt) do (
if !count!==1 set FName=%%a
if !count!==2 set LName=%%a
if !count!==3 set UName=%%a
if !count!==4 set UName=%%a
set /a count+=1
)

%windir%\system32\REG.exe ADD “HKEY_LOCAL_MACHINE\SOFTWARE\Scan” /v “First Name” /t REG_SZ /d “%FNAME%” /f
%windir%\system32\REG.exe ADD “HKEY_LOCAL_MACHINE\SOFTWARE\Scan” /v “Last Name” /t REG_SZ /d “%LNAME%” /f
%windir%\system32\REG.exe ADD “HKEY_LOCAL_MACHINE\SOFTWARE\Scan” /v “User Name” /t REG_SZ /d “%UNAME%” /f
%windir%\system32\REG.exe ADD “HKEY_LOCAL_MACHINE\SOFTWARE\Scan” /v “Email Address” /t REG_SZ /d “%Email%” /f

email me