Unfortunately, I cannot find any place in registry saying that 3.0 version of framework is installed. I am using the following code supposing that v3.0 sub-branch is always presenting under .NETFramework branch:
; The function checks if a computer has .NET Framework 3.0 installed
Var WinFxFound ; if .NET Framework 3.0 found
Function CheckFrameworkWinFx
StrCpy $WinFxFound 0
ReadRegStr $0 HKLM "Software/Microsoft/.NETFramework/v3.0" ""
StrCpy $0 0
loop:
EnumRegKey $1 HKLM "Software\Microsoft\.NETFramework" $0
StrCmp $1 "" done
IntOp $0 $0 + 1
${if} $1 == "v3.0"
StrCpy $WinFxFound 1
${else}
goto loop
${endif}
done:
${if} $WinFxFound == 0
${endif}
FunctionEnd