Hi Programm3r,
I'm answering using Ubuntu right now so I couldn't test it right now but what you're looking for is something like:
For /F %%A In ('reg query "HKEY_Local_Machine\Software\Microsoft\NET Framework Setup\NDP\v3.5" /v Install') do goto skip
Echo reg value not found
goto done
:skip
Echo reg value found
:done
Good luck!