Declare Sub Main

Declare Function GetComputerName Lib "kernel32" Alias "GetComputerNameA"
(lpBuffer As String, nSize As Integer) As Integer

Sub Main

Dim lpBuffer As String

Dim nSize As Integer

Dim nErr As Integer

lpBuffer = String$(255," ")

nSize = 255

nErr = GetComputerName(lpBuffer,nSize)

Note "lpBuffer: " + lpBuffer

End Sub

 
 

HTH

Jakob Lanstorp 
Software Consultant 
Geographical Information & IT 

COWI A/S 
Odensevej 95 
5260 Odense S. 

Tel   +45 6311 4900 
Fax  +45 6311 4949 
Mob +45 5050 8087 
E-mail [EMAIL PROTECTED] 
http://www.cowi.dk <http://www.cowi.dk/>  
http://www.cowi.com <http://www.cowi.com/>  

-----Original Message-----
From: Percival, Mark [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 04, 2005 12:48 PM
To: '[email protected]'
Subject: MI-L Computer Name


Has anyone got a function to return the computer name (not the
Username)?  I know I've seen it somewhere but can't remember!
 
Your help would be gratefully received.
 
Regards,
 
Mark Percival
Data Standards Manager
Customer & Business Services
Coventry City Council
Tel: 024 7683 2540

 


This e-mail and any files transmitted with it are confidential and are
intended solely for the use of the addressee. If you have received this
e-mail in error, you are requested to contact the sender immediately,
and not to disclose or make use of this information. 

All e-mails are monitored by Coventry City Council IT Security, using
Star Filtering Services.

The views contained in this e-mail are those of the author and not
necessarily those of Coventry City Council.
______________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs.

Reply via email to