Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Class for transforming paires into dozens & vice versa
Message
De
21/10/1998 14:53:58
 
 
À
21/10/1998 14:45:26
Pierre Sauve
Micro-Fox Canada Inc.
Montréal, Québec, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00149030
Message ID:
00149038
Vues:
16
Hi Pierre ----

Are you saying that the user will see and enter in dozens but the data will be stored as units? Why not store this information in 2 separate fields and have the second field be units and calculated in a stored procedure in the database container?


> I am trying my best to learn VFP . But I have a problem that I dont seem to be able to solve. I would need guidlines on this if possible .
>I am writing an application where quantities for a Unit of Measure = "DZS" are kept on disk in pairs , but when one look at them on the screen or on a report , these quantities are shown in dozens and pairs. Example a field containing 138 on disk as a quantity would show 11.06 on a screen or a report . That is read by the user as 11 dzs and 6 pairs.(int(138/12) = 11 and mod(138,12) = 6 wich is formatted to show 06). This is typical of the hosiery industry. So , I would need 2 class's . One to go from the disk to the screen and on to go from to screen (after user change or not) to the disk. I know how to write the code , wich is very simple . But what I seem to be missing is Where to create the class , wich property do I need to create and where , in the form or in the class. No matter what I have tried so far do not work .
> Can someone give general guidelines on this please ?
>
>
> Thanks in advance.
>
> Pierre Sauve
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform