Not accept a value of 0 in a currency field.

G

Guest

In a cost savings field I want to not accept a savings of 0, but a cost of
less than or greater than 0 is acceptable. In my projects database there is
a cost saving field and the engineers are getting around it by putting in a 0
so I want to force them to put in an acceptable value. for example the
savings might be $1.99 or ($1.99) but not $0.00. How can i do that.
 
G

Guest

Here is another option if you want to have control over the message box that
displays when the rule is violated. This code would go in the controls After
Update event.


If Me.FieldName = 0 Then
MsgBox "You cannot enter 0 in this field"
Me.FieldName.SetFocus

End If
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top