Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Matematical question
Message
From
16/01/2019 16:54:18
Luis Santos
Biglevel-Soluções Informáticas, Lda
Portugal
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Matematical question
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Network:
Windows Server 2012 R2
Database:
MS SQL Server
Application:
Desktop
Miscellaneous
Thread ID:
01665476
Message ID:
01665476
Views:
96
Hello community

I have several pairs of shoes to put in boxes of 10 pairs
I need to sum each line to know when it reaches the 10 pairs.

If adding the lines exceeds the 10 pairs, I have to save this value (remainder) to sum to the next line Quantity and then check again if the result is bigger than 10, if not , i must continue to sum with the next line quantity until you reach the 10 pairs, and so on.
That is, I have to make the maximum of boxes of 10 pairs, what remains will be less than 10 pairs, soon it will go in a different box with less pairs.

Someone could give me a small example to try to do this, for example with a VFP cursor.
Many thanks
Luis
Next
Reply
Map
View

Click here to load this message in the networking platform