>>
>>Hi,
>>
>>You can write special UDF for 64 bit numbers and call if you need it.
>>
>>LOCAL m.lnX, m.lii
>>m.lnX=0xFFFFFFFF+1
>>
>>FOR m.lii=1 TO 32
>>?m.lii, VFP64_BITTEST(m.lnX, m.lii)
>>NEXT
>>RETURN
>>
>>PROCEDURE VFP64_BITTEST
>>LPARAMETERS m.nNumericExpression1, m.nBitNumber
>>RETURN IIF(m.nBitNumber<=31, BITTEST(m.nNumericExpression1, m.nBitNumber), BITTEST(m.nNumericExpression1/(0x100000000), m.nBitNumber-32))
>>RETURN
>>
.
>>
>>MartinaJ
>
>Martina,
>
>Unfortunately, VFP lacks precision with large numbers.
>
>
>FOR m.Bit = 32 TO 48
> ? m.Bit, VFP64_BITTEST(0x0FFFFFFFFFFFF, m.Bit)
>ENDFOR
>
>
>There is no safe way for doing this in VFP using numeric types, I believe, as Dragan remarked.
Ok, after playing around with Martina's solution, I discovered that you (Antonio) are right. The VFP64_BitTest routine does not provide the results I am looking for. But it does send me in the right direction.
Greg Reichert