T
Tom
I am in access 2007 and I have a table called inventory with the following
fields included:
I have a field called [restock level] and it is numeric
a field called [current purchases] which is numeric
and a field called [current inventory level] which is numeric
I created a query and included a calculated field called todays inventory
which subtracts [current purchases] from the [current inventory level]
I created a report based on the inventory query . it could just as easily be
a form
In that report I would like a message to display if the number in [todays
inventory] is less than or equal to the [restock level]
i created a warning label saying that reorder immmediately
I named the label restockmsg
I made some simple code and tried to attach it to the todays inventory field
If [todays inventory] <= [restock level] Then
[restockmsg].Visible = True
[restock level].ForeColor = 255
Else
[restockmsg].Visible = False
[restock level].ForeColor = 0
End Sub
I would like to attach it to the after update field but there is no after
update field in the events . I am not sure wheer I have gone wrong.
Any suggestions would be appreciated
Thanks
Tom
fields included:
I have a field called [restock level] and it is numeric
a field called [current purchases] which is numeric
and a field called [current inventory level] which is numeric
I created a query and included a calculated field called todays inventory
which subtracts [current purchases] from the [current inventory level]
I created a report based on the inventory query . it could just as easily be
a form
In that report I would like a message to display if the number in [todays
inventory] is less than or equal to the [restock level]
i created a warning label saying that reorder immmediately
I named the label restockmsg
I made some simple code and tried to attach it to the todays inventory field
If [todays inventory] <= [restock level] Then
[restockmsg].Visible = True
[restock level].ForeColor = 255
Else
[restockmsg].Visible = False
[restock level].ForeColor = 0
End Sub
I would like to attach it to the after update field but there is no after
update field in the events . I am not sure wheer I have gone wrong.
Any suggestions would be appreciated
Thanks
Tom