Two alternate possibilities:
One is conceptual. Consider why you are asking the user. Is it because you have a program or website that requires a specific version? If so, you are expected to distribute the proper redist package with your application.
Also conceptually, instead of making the user jump through hoops, why not write a native application that presents the information? I mean, you probably are planning on installing software on the users machine anyway, why not have a program that can do this?
Finally, if you just want a list of installed versions have the user execute the following at the command prompt:
reg query "HKLM\SOFTWARE\Microsoft\NET Framework Setup\NDP" /v Version /s