Results 1 to 2 of 2

Thread: RE: How to read Computer Name?

  1. #1
    Guest

    Post

    How can I find the computer name which found on "Network -> Identification tab"?

    Thanx.

    SK

  2. #2
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Post

    Use the GetComputerName API Function:

    Public Declare Function GetComputerName _
    Lib "kernel32" Alias "GetComputerNameA" ( _
    ByVal lpBuffer As String, _
    nSize As Long) As Long

    Public Function ComputerName() As String
    Dim sName As String
    sName = Space(25)
    Call GetComputerName(sName, 25)
    ComputerName = sName
    End Function

    Good luck!

    ------------------
    Joacim Andersson
    [email protected]
    [email protected]
    www.YellowBlazer.com



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width