Reputation: 1719
Using Visual Basic 6, what is the best way to detect if the .NET Framework is installed on a client machine, and what versions of .NET are installed?
Upvotes: 1
Views: 2483
Reputation: 1719
I was able to answer my own question with the following code based.
Dim strFrameworkDir As String
strFrameworkDir = Environ$("systemroot") & "\Microsoft.NET\Framework\v3.5"
If Dir$(strFrameworkDir, vbDirectory) = vbNullString Then
MsgBox ".NET Framework 3.5 Must be Installed on this machine!"
End
End If
Upvotes: 2
Reputation: 7351
you may take this information from windows system registry. HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft.NETFramework\
Upvotes: 2
Reputation: 887385
Check the subfolders in the %systemroot%\Microsoft.NET\Framework
folder.
Upvotes: 5