Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Yousfi Benameur
  Where is Yousfi Benameur?
 El Bayadh
 Algeria
 Yousfi Benameur
 To: Leonid Lepin
  Where is Leonid Lepin?
 Riga
 Latvia
 Leonid Lepin
 Tags
Subject: RE: Hard Disk Serial No.
Thread ID: 268084 Message ID: 268921 # Views: 54 # Ratings: 0
Version: Visual FoxPro 9 SP2 Category: Security and Application Protection
Date: Thursday, July 15, 2010 1:01:31 PM         
   


> Probably this code will give what you see on the HDD label
>
>
> m.sco1="32564c325a504741202020202020202020202020"
> 
> m.sn=""
> m.pos3=1
> for m.j=1 to 20
> 	m.ch1=chr(eval("0x"+allt(substr(m.sco1,m.pos3,2))))
> 	m.pos3=m.pos3+2
> 	m.ch2=chr(eval("0x"+allt(substr(m.sco1,m.pos3,2))))
> 	m.pos3=m.pos3+2
> 	m.sn=m.sn+m.ch2+m.ch1
> endfor
> m.sn=allt(chrtran(m.sn,chr(0),""))
> ?m.sn
> 

>
> Leonid

Hi Lepin i meet you in first time in the forum, welcome.
I inform you i never working with serial HD number and needed it anywhere :-)

If i make a syntese of all methods invoked in this thread (tested on my PC):
-APIS  Method return
C:\   Vol SN: 4891BB30  NTFS #  Model: Maxtor 6V080E0   Revision: VA111900   Serial: V22LPZAG

-WMI Win32_DiskDrive return
PNP DeviceID: IDE\DISKMAXTOR_6V080E0__________________________VA111900\32564C325A504741202020202020202020202020

-method (WMI physical media) return
32564c325a504741202020202020202020202020   

-2nd Lepin Method  :          V22LPZAG     (this joins the apis method)                                          

in win32_physicalMedia serialNumber is available.That is not the case in win32_diskDrive

SerialNumber

Data type: string
Access type: Read-only

Number allocated by the manufacturer to identify the physical media.

Example: WD-WM3493798728

Windows Server 2003, Windows XP, Windows 2000, and Windows NT 4.0: This property is not available. but PNPDeviceID is available.


What is the method currently used by specialists in this domain and showing 100% Guarantee ?

Regards
Yousfi Benameur

ENTIRE THREAD

Hard Disk Serial No. Posted by gaurav sharma @ 7/8/2010 1:58:07 PM
RE: Hard Disk Serial No. Posted by Glen Villar @ 7/8/2010 2:02:39 PM
RE: Hard Disk Serial No. Posted by loo peng @ 7/10/2010 11:37:39 AM
RE: Hard Disk Serial No. Posted by Mike Gagnon @ 7/10/2010 12:28:37 PM
RE: Hard Disk Serial No. Posted by khubaib khalid @ 7/11/2010 8:01:36 AM
RE: Hard Disk Serial No. Posted by Mike Gagnon @ 7/11/2010 12:29:41 PM
RE: Hard Disk Serial No. Posted by khubaib khalid @ 7/11/2010 12:45:18 PM
RE: Hard Disk Serial No. Posted by tushar @ 7/8/2010 2:06:02 PM
RE: Hard Disk Serial No. Posted by gaurav sharma @ 7/8/2010 2:12:05 PM
RE: Hard Disk Serial No. Posted by tushar @ 7/8/2010 3:49:59 PM
RE: Hard Disk Serial No. Posted by gaurav sharma @ 7/9/2010 7:55:49 AM
RE: Hard Disk Serial No. Posted by tushar @ 7/9/2010 8:20:11 AM
RE: Hard Disk Serial No. Posted by Leonid Lepin @ 7/8/2010 3:12:58 PM
RE: Hard Disk Serial No. Posted by tom knauf @ 7/9/2010 5:07:52 PM
RE: Hard Disk Serial No. Posted by loo peng @ 7/10/2010 11:35:57 AM
RE: Hard Disk Serial No. Posted by tom knauf @ 8/20/2010 4:41:05 PM
RE: Hard Disk Serial No. Posted by Yousfi Benameur @ 7/13/2010 3:23:31 PM
RE: Hard Disk Serial No. Posted by Mike Gagnon @ 7/14/2010 2:17:28 AM
RE: Hard Disk Serial No. Posted by Yousfi Benameur @ 7/14/2010 12:27:02 PM
RE: Hard Disk Serial No. Posted by Mike Gagnon @ 7/15/2010 3:09:38 AM
RE: Hard Disk Serial No. Posted by Yousfi Benameur @ 7/15/2010 8:28:43 AM
RE: Hard Disk Serial No. Posted by Leonid Lepin @ 7/15/2010 10:34:12 AM
RE: Hard Disk Serial No. Posted by Yousfi Benameur @ 7/15/2010 1:01:31 PM
RE: Hard Disk Serial No. Posted by Adam Walan @ 7/13/2010 7:40:36 PM
RE: Hard Disk Serial No. Posted by Mike Gagnon @ 7/14/2010 2:19:09 AM
RE: Hard Disk Serial No. Posted by marcelo ferrone @ 10/17/2010 5:44:32 PM