Toolz,
You mean if there are multiple cartridges in your database which are
"low", and you want the message box to include all of them? Hmmm, well
that is theoretically possible, but I would suggest that a MsgBox is not
really the appropriate approach with this. I would try it like this
instead...
Make a query based on your table, with a Criteria <4 in the Quantity field.
Make a continuous view Form based on this query.
On the After Update event of the existing form (not the Quantity
control), put code like this...
Private Sub Form_AfterUpdate()
If DCount("*","YourQuery") > 0 Then
DoCmd.OpenForm "Your New Form"
End If
End Sub
For the record, to do it with the MsgBox idea, the code would be
something like this...
Private Sub Quantity_Exit(Cancel As Integer)
Dim rst as DAO.Recordset
Dim MessageText As String
Me.Dirty = False
Set rst = CurrentDb.OpenRecordset("SELECT [Type of Cartridge] FROM
YourTable WHERE Quantity < 4")
Do Until rst.EOF
MessageText = MessageText & rst![Type of Cartridge] & vbCrLf
rst.MoveNext
Loop
rst.Close
If Len(MessageText) Then
MsgBox "Ink is low:" & vbCrLf & MessageText
End If
Set rst = Nothing
End Sub

Signature
Steve Schapel, Microsoft Access MVP
> ok! that did tell what cartfride is low, but can i have it tell me all the
> cartridge that are low on every exit. Right now it will tell you if the
> cartridge is low is you have just reduce it then when exiting will tell you
> cartridge is low. Can I have it do that wil out and up date at the exit.
Toolz2life - 06 Sep 2006 16:35 GMT
Steve,
Thank for the for the info. I am trying it with the Msbox and I am putting
the code in and when i run the program i am getting a syntax error at the
point "("SELECT [Type of Cartridge] FROM YourTable WHERE Quantity < 4")".
Where you put "FROM YourTable WHERE Quantity" I delet that and put the name
of the table by it self, which is Quantity. I know a little code-in but not
enough to know what i am doing wrong.
Thank,
Toolz
> Toolz,
>
[quoted text clipped - 36 lines]
> > cartridge is low is you have just reduce it then when exiting will tell you
> > cartridge is low. Can I have it do that wil out and up date at the exit.
Steve Schapel - 18 Sep 2006 09:21 GMT
Toolz,
Can you please post back with the complete code you are using?

Signature
Steve Schapel, Microsoft Access MVP
> Steve,
> Thank for the for the info. I am trying it with the Msbox and I am putting
[quoted text clipped - 3 lines]
> of the table by it self, which is Quantity. I know a little code-in but not
> enough to know what i am doing wrong.