A
A Hopper
I was late responding to your answer regarding my Rounding
Up and Down question. I have downloaded Ken Getz' rounding
function from
http://www.mvps.oprg/access/modules/md10054.htm, however,
I do not understand how it works or how to call it.
On a form "SixDifinPackageForm" are textboxes "MasterQty"
and "NumberOfPositions" which I want to divide and round
up and down to the nearest 10, 100 etc.. When the form
opens the textboxes receive their values from a form
called "PackSetUp". The On Open event of
the "SixDifinPackageForm" get the value for "MasterQty"
and "NumberOfPositions" from a form called "PackSetUp". I
also want to use the On Open event to call Ken Getz'
rounding function.
Example:
"MasterQty" value is 2000, "NumberOfPositions" value is 6,
(Me.MasterQty)/(Me.NumberOfPositions) = 333.3
Round down to 300
Round up to 400
Dim MaxRequired As Single
Dim MinRequired As Single
MaxRequired = 400
MinRequired = 300
Rounding depends on the answer to (Me.MasterQty)/
(Me.NumberOfPosition)
20/6 = 3.3 Round up 4 Round down 3
200/6 = 33.3 Round up to 40 Round down to 30 (nearest 10)
2000/6 = 333.3 Round up to 400 Round down to 300
(nearest 100)
Even if Ken Getz' rounding is not what I need for what I
am trying to do I would like to understand how to use it.
Thanks for you help
Allan
Up and Down question. I have downloaded Ken Getz' rounding
function from
http://www.mvps.oprg/access/modules/md10054.htm, however,
I do not understand how it works or how to call it.
On a form "SixDifinPackageForm" are textboxes "MasterQty"
and "NumberOfPositions" which I want to divide and round
up and down to the nearest 10, 100 etc.. When the form
opens the textboxes receive their values from a form
called "PackSetUp". The On Open event of
the "SixDifinPackageForm" get the value for "MasterQty"
and "NumberOfPositions" from a form called "PackSetUp". I
also want to use the On Open event to call Ken Getz'
rounding function.
Example:
"MasterQty" value is 2000, "NumberOfPositions" value is 6,
(Me.MasterQty)/(Me.NumberOfPositions) = 333.3
Round down to 300
Round up to 400
Dim MaxRequired As Single
Dim MinRequired As Single
MaxRequired = 400
MinRequired = 300
Rounding depends on the answer to (Me.MasterQty)/
(Me.NumberOfPosition)
20/6 = 3.3 Round up 4 Round down 3
200/6 = 33.3 Round up to 40 Round down to 30 (nearest 10)
2000/6 = 333.3 Round up to 400 Round down to 300
(nearest 100)
Even if Ken Getz' rounding is not what I need for what I
am trying to do I would like to understand how to use it.
Thanks for you help
Allan