>>>Hi,
>>> Can anyone give me some idea or API name to get the serial number of the ethernet card installed on a CPU. How can we call a function of an API? I am working on vfp 7.
>>> Thanks in advance,
>>>
>>>Regards/ Somesh
>>
>>One of the ways:
>>
>>Declare Integer CoCreateGuid In 'OLE32.dll' ;
>> string @pguid
>>Declare Integer StringFromGUID2 In 'OLE32.dll' ;
>> string rguid, String @lpsz, Integer cchMax
>>Declare Integer UuidCreateSequential In 'RPCRT4.dll' String @ Uuid
>>
>>pGUID=Replicate(Chr(0),16)
>>rGUID=Replicate(Chr(0),80)
>>lcOldError = On('error')
>>On Error lnResult = CoCreateGuid(@pGUID)
>>lnResult = UuidCreateSequential(@pGUID)
>>On Error &lcOldError
>>lcMacAddress = Substr( Iif( lnResult = 0 And ;
>> StringFromGUID2(pGUID,@rGUID,40) # 0, ;
>> StrConv(Left(rGUID,76),6), "" ), 26,12)
>>
>>? m.lcMacAddress
>>
Cetin
>
>Dear Cetin,
>I read that "a GUID, or globally unique identifier, is a number that Microsoft guarantees is unique throughout the entire world".
>I want to know can i use from this unique identifier for making a software LOCK?
>Is it possible that this value changed if user change it's Hardware or it's OS ( such as upgrade WIN98 to WIN XP? ) or any change in it's computer?
>This GUID generate based on what? hardware? or anything
>Thanks for your guide
If you're asking for GUID user need not to change something, the value changes with each call. In other words you generate a value once. Generated with few components (such as time,network card,randomizing). You might generate a software lock based on value but you need to use your own imagination to find out how.
Cetin