PDA

Click to See Complete Forum and Search --> : GetSystemInfo API


DACOSTA2
Dec 4th, 1999, 01:09 AM
I use GetSystemInfo API to read disk serial number and protect my aplication. But it does not work in NT!!!

Somebody knows which API to use ?

Thanks in advance

Ruben
Montevideo, Uruguay

MartinLiss
Dec 4th, 1999, 02:09 AM
I use GetSystemInfo under NT without any problem although I don't use it for the same purpose as you. Here is what I do:
Declare Sub GetSystemInfo Lib "Kernel32" (lpSystemInfo As SystemInfo)

Public Type SystemInfo
dwOemId As Long
dwPageSize As Long
lpMinimumApplicationAddress As Long
lpMaximumApplicationAddress As Long
dwActiveProcessorMask As Long
dwNumberOfProcessors As Long
dwProcessorType As Long
dwAllocationGranularity As Long
dwReserved As Long
End Type

' And then in a subroutine
Dim YourSystem As SystemInfo
GetSystemInfo YourSystem

lblPCPU.Caption = "CPU: " & YourSystem.dwProcessorType



------------------
Marty

christophe
Dec 4th, 1999, 07:15 PM
Marty,

Any way you can get the CPU serial number?