>>Yes, it seems vb interpretes those as signed
>>
>>
http://msdn.microsoft.com/en-us/library/s9cz43ek.aspx>>
>>Append the type to the constant. U and I
>>
>> Dim lnCRC32Result As UInteger = &HFFFFFFFFUI
>>
>
>Thanks, in regards to that issue, yes, it does allows to define UInteger with HEX values.
Right. Concerning the negative/positive matter. It's the structure of the bits that matters, not whether you look at it as signed or unsigned
In Foxpro
xx = repl(chr(0xff), 4)
crc32 = sys(2007, m.xx,-1,1)
?crc32 && 4294967295
?vartype(crc32) && C
?int(val(crc32)) && 4294967295
&& Force a signed 32 bit integer
?bitor(int(val(crc32)), 0) && -1
Gregory