Get User Name
Returns the current user name using a dll call
AI
AI சுருக்கம்: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.
மூலக் குறியீடு
Function GetUser() ' This function uses a windows dll to query the registry automatically ti return the user name Dim sBuffer As String Dim lSize As Long ' Parameters for the dll declaration are set sBuffer = Space$(255) lSize = Len(sBuffer) Call GetUserName(sBuffer, lSize) ' Call the declared dll function If lSize > 0 Then GetUser = Left$(sBuffer, lSize) ' Remove empty spaces Else GetUser = vbNullString ' Return empty if no user is found End If End Function Upload Upload
அசல் கருத்துகள் (3)
வேபேக் மெஷினிலிருந்து (Wayback Machine) மீட்டெடுக்கப்பட்டது