by Dharmesh Hirpara (1 Submission)
Category: Windows API Call/Explanation
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Sat 29th December 2001
Date Added: Mon 8th February 2021
Rating: (1 Votes)
From this code we will get a Harddisk serialNumber and Modelnumber. Because of Each harddisk has a unique serialno,We can use this serialno to
API Declarations
Public Declare Function GetModelNumber Lib "DiskSerial.dll" (ByVal nDrive As Integer, ByVal lpBuffer As String) As Long
'From that Yor will get Your Harddisk serialNumber and Modelnumber
'Because of Each harddisk has a unique serialno,We can use this serialno
'to protect any application from other harddisks if the HDDserialno is not match
'then exit from the application
Private Sub Command1_Click()
Dim HDDserialno As String * 256
Call GetSerialNumber(0, HDDserialno)
MsgBox HDDserialno
End Sub
Private Sub Command2_Click()
Dim HDDModelno As String * 256
Call GetModelNumber(0, HDDModelno)
MsgBox HDDModelno
End Sub
No comments have been posted about From this code we will get a Harddisk serialNumber and Modelnumber. Because of Each harddisk has a . Why not be the first to post a comment about From this code we will get a Harddisk serialNumber and Modelnumber. Because of Each harddisk has a .