[AccessD] Mac address

DJK(John) Robinson djkr at msn.com
Tue Jan 6 13:35:20 CST 2004


This gives me  1234567890  for my SuperMicro m'board (under WinXP Pro, AXP,
MS WMI Scripting V1.2 Library).

So ... maybe not so useful.

John


> -----Original Message-----
> From: accessd-bounces at databaseadvisors.com 
> [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of 
> Stuart McLachlan
> Sent: 05 January 2004 00:40
> To: Access Developers discussion and problem solving
> Subject: RE: [AccessD] Mac address
> 
> 
> On 4 Jan 2004 at 17:43, John Bartow wrote:
> 
> > I was just wondering why the Main Circuit Board Serial Number isn't 
> > used for this. It would seem to me that this would be about 
> the most 
> > stable unique ID number in a PC. I have no idea how you would read 
> > this number but it always shows up in my hardware asset inventories.
> > 
> > Any comments?
> 
> Public Function MBSerialNumber() As String
> 
> 'RETRIEVES SERIAL NUMBER OF MOTHERBOARD
> 'IF THERE IS MORE THAN ONE MOTHERBOARD, THE SERIAL
> 'NUMBERS WILL BE DELIMITED BY COMMAS
> 
> 'YOU MUST HAVE WMI INSTALLED AND A REFERENCE TO
> 'Microsoft WMI Scripting Library IS REQUIRED
> 
> Dim objs As Object
> 
> Dim obj As Object
> Dim WMI As Object
> Dim sAns As String
> 
> 
> Set WMI = GetObject("WinMgmts:")
> Set objs = WMI.InstancesOf("Win32_BaseBoard")
> For Each obj In objs
>   sAns = sAns & obj.SerialNumber
>  If sAns < objs.Count Then sAns = sAns & ","
> Next
> MBSerialNumber = sAns
> End Function
>  
> -- 
> Lexacorp Ltd
> http://www.lexacorp.com.pg
> Information Technology Consultancy, Software 
> Development,System Support.
> 
> 
> 
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com 
> http://databaseadvisors.com/mailman/listinfo/a> ccessd
> Website: 
> http://www.databaseadvisors.com
> 


More information about the AccessD mailing list