K
KellyS
Hello.
I have a main form and subform to track printer cartridge inventory. THe
main form hase cartridge info and the subform tracks the inventory history. I
want a message box to pop up when the # of cartridges on hand (UnitsOnHand)
is <= # of cartridges given away (UnitsDist) and to say "Listen up! It's time
to reorder this cartridge".
I am having touble finding the correct spot for the event to fire. I need
to...
1. Enter the units given away (UnitsDist on subform)
2. Update the calculation (a control with this expression is on the subform
and is viewed on the main form) (=Sum(nz([UnitsReceived])-nz([UnitsDist]))
3. Compare that to the ReOrderLevel (the control for this is on the Main
Form) (if UnitsOnHand <= ReorderLevel Then...)
4. Pop up a message box that says it's time to reorder.
......all before I move to the next record on the subform.
Do I put it in the MainForm events? exactly which? On Current? or the
SubForm Control on the Main Form? or in SubForm events? or on the UnitsDist
control on the subform?
I have tried many events/locations. I want to see a popup after i enter the
# given away and before I move to the next record. I am not sure the sequence
of how the events work.
Please let me know if more info is needed. Any suggestions are greatly
appreciated!
I have a main form and subform to track printer cartridge inventory. THe
main form hase cartridge info and the subform tracks the inventory history. I
want a message box to pop up when the # of cartridges on hand (UnitsOnHand)
is <= # of cartridges given away (UnitsDist) and to say "Listen up! It's time
to reorder this cartridge".
I am having touble finding the correct spot for the event to fire. I need
to...
1. Enter the units given away (UnitsDist on subform)
2. Update the calculation (a control with this expression is on the subform
and is viewed on the main form) (=Sum(nz([UnitsReceived])-nz([UnitsDist]))
3. Compare that to the ReOrderLevel (the control for this is on the Main
Form) (if UnitsOnHand <= ReorderLevel Then...)
4. Pop up a message box that says it's time to reorder.
......all before I move to the next record on the subform.
Do I put it in the MainForm events? exactly which? On Current? or the
SubForm Control on the Main Form? or in SubForm events? or on the UnitsDist
control on the subform?
I have tried many events/locations. I want to see a popup after i enter the
# given away and before I move to the next record. I am not sure the sequence
of how the events work.
Please let me know if more info is needed. Any suggestions are greatly
appreciated!