Code to get computer name in vb.net

Public Function GetComputerName() As String

Return System.Environment.MachineName

End Function