Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Creating a 'packed' decimal for IBM mainframe upload
Message
 
 
À
21/09/1998 12:02:49
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00139013
Message ID:
00139082
Vues:
25
...snip...
>Another example: a value of -32767 would be represented as:
> |32|76|7B| or |32|76|7E| again assuming that a 3-byte field was wanted. By the way I feel a little unsure about the negative signs (not what you want to hear, I'm sure) but you can be certain that "F"is the standard for a positive number.
>
>hope this helps,
>
>Jim N

Jim, you are correct. 'F' is the standard for unsigned which is treated as postive. The standard for postive is 'C' and for negative is 'D'. This is what Gerry's code does where he adds '12' (hex C) or '13' (hex D) to the offset for a signed number, or '15' (hex F) for an unsigned number.

Rick
Rick Borup, MCSD

recursion (rE-kur'-shun) n.
  see recursion.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform