Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
BINTOC()
Message
From
27/04/2001 13:29:11
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00500863
Message ID:
00500893
Views:
32
This message has been marked as a message which has helped to the initial question of the thread.
>I expected that the result of bintoc(0,1) would be chr(0) - in fact it is chr(128), or 80 hex. Further tests showed that all bintoc() results have 128 added to the most significant byte.
>Ex:
>bintoc(255) results in chr(128)+chr(255) (hex 80 FF)
>bintoc(256) results in chr(129)+chr(0) (hex 81 00)
>
>Why is this?
>
>TIA

So it reserves for negative numbers. It uses it as a flag also. For neg numbers it's less than 128 down to 0.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform