Hi All,
I have this code, snippet below, to read a registry key in the HKLM class. It works. But the problem is, it reads the registry of the IIS server, not the client connecting. Does anyone know what I need to do so that I can read the remote computer's registry file?
I call this function from the Private Sub Page_Load event of the ASP page. An example follows...
Thanks a bunch,
MapMan![[americanflag] [americanflag] [americanflag]](/data/assets/smilies/americanflag.gif)
Assume nothing, question everything, be explicit not implicit, and you'll always be covered.
I have this code, snippet below, to read a registry key in the HKLM class. It works. But the problem is, it reads the registry of the IIS server, not the client connecting. Does anyone know what I need to do so that I can read the remote computer's registry file?
Code:
Private Sub ChkFramework()
Dim aKey As RegistryKey = Registry.LocalMachine
Dim oKey As RegistryKey
Dim oTheValue As Object
Dim szResult As String = ""
Try
oKey = aKey.OpenSubKey(CStr("software\\microsoft\\.netframework\\policy\\v1.0"), False)
oTheValue = oKey.GetValue(CStr("3705"), "")
If (Not oTheValue Is Nothing) Then
szResult = oTheValue
Else
szResult = ""
End If
Catch ex As Exception
Finally
If szResult <> "3321-3705" Then
lblFrmStat.Text = "Not Installed"
lblFrmStat.Font.Bold = True
hypFrm.NavigateUrl = "[URL unfurl="true"]http://localhost/NetNetWeb/netfx.msi"[/URL]
hypFrm.Text = "Install/Upgrade .Net Framework"
Else
lblFrmStat.Text = "Installed"
lblFrmStat.Font.Bold = False
hypFrm.NavigateUrl = ""
hypFrm.Text = "None"
End If
End Try
End Sub
I call this function from the Private Sub Page_Load event of the ASP page. An example follows...
Code:
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Call ChkFramework()
Call DisplayHelp()
End Sub
Thanks a bunch,
MapMan
![[americanflag] [americanflag] [americanflag]](/data/assets/smilies/americanflag.gif)
Assume nothing, question everything, be explicit not implicit, and you'll always be covered.