Is there a way to get the user name from a client PC in ASP? For example, in VB I use the following code to get the name of the user that is currently logged on to the PC:
Declare Function GetUserName Lib "advapi32.dll" Alias "GetUserNameA" (ByVal lpBuffer As String, nSize As Long) As Long
Function GetUser() As String
Dim lpUserID As String
Dim nBuffer As Long
Dim Ret As Long
lpUserID = String(25, 0)
nBuffer = 25
Ret = GetUserName(lpUserID, nBuffer)
If Ret Then
GetUser$ = lpUserID$
End If
End Function
Is there any way I can duplicate this in ASP?
Declare Function GetUserName Lib "advapi32.dll" Alias "GetUserNameA" (ByVal lpBuffer As String, nSize As Long) As Long
Function GetUser() As String
Dim lpUserID As String
Dim nBuffer As Long
Dim Ret As Long
lpUserID = String(25, 0)
nBuffer = 25
Ret = GetUserName(lpUserID, nBuffer)
If Ret Then
GetUser$ = lpUserID$
End If
End Function
Is there any way I can duplicate this in ASP?