Ver Mensaje Individual
  #3 (permalink)  
Antiguo 03/01/2006, 07:53
hunabku
 
Fecha de Ingreso: diciembre-2003
Mensajes: 595
Antigüedad: 20 años, 5 meses
Puntos: 1
Cita:
Iniciado por luciano
Sacado del Apiguide:

'example by Donavon Kuhn ([email protected])
Private Const MAX_COMPUTERNAME_LENGTH As Long = 31
Private Declare Function GetComputerName Lib "kernel32" Alias "GetComputerNameA" (ByVal lpBuffer As String, nSize As Long) As Long
Private Sub Form_Load()
Dim dwLen As Long
Dim strString As String
'Create a buffer
dwLen = MAX_COMPUTERNAME_LENGTH + 1
strString = String(dwLen, "X")
'Get the computer name
GetComputerName strString, dwLen
'get only the actual data
strString = Left(strString, dwLen)
'Show the computer name
MsgBox strString
End Sub



Mi web sobre Visual:
http://ar.geocities.com/recursosvb
muchas gracias luciano