Share via


My.Computer.Registry Property 

Gets an object that provides properties and methods for manipulating the registry.

' Usage
Dim value As Microsoft.VisualBasic.MyServices.RegistryProxy = My.Computer.Registry
' Declaration
Public ReadOnly Property Registry As RegistryProxy

Return Value

This property returns the My.Computer.Registry Object for the computer.

Remarks

This property provides easy access to the My.Computer.Registry Object.

Example

This example reads the value Name from HKEY_CURRENT_USER\Software\MyApp and displays it in a message box.

Dim readValue As Object
        readValue = My.Computer.Registry.GetValue _
        ("HKEY_CURRENT_USER\Software\MyApp", "Name", Nothing)
        MsgBox("The value is " & CStr(readValue))

Requirements

Namespace: Microsoft.VisualBasic.Devices

Class: Computer, ServerComputer

Assembly: Visual Basic Runtime Library (in Microsoft.VisualBasic.dll)

Permissions

No permissions are required.

See Also

Reference

My.Computer Object
My.Computer.Registry Object

Concepts

Common Registry Tasks