|set /p var=Line# ? |
for /f "tokens=1,2*" %%a in ('findstr %var% tmp.tmp') do echo Line number is %%a, value is %%b
that will give you the line number and the value as an echo, you can run any set commands that you want to.
not sure what you mean by take out number, the %%b gives you that value already.