Hi - what property do I need to set in order for a pos number to be changed to a neg # when entered. Example: User enters 10, once they tab off that field, it auto changes to a neg value.
thanks
Hi - what property do I need to set in order for a pos number to be changed to a neg # when entered. Example: User enters 10, once they tab off that field, it auto changes to a neg value.
thanks
why don't you do this:Code:control_onblur() me.control.value = me.control.value - (me.control.value * 2)That'll work!!
For a Form, you could use a VBA (AfterUpdate event) procedure to calculate the Textbox control to a negative number as a calculation.
If your Textbox control is called TextBox1 then something like:
TextBox1 = TextBox 1 * -1
This works for either an Unbound/Bound control in a Form.
Alternatively, you could create a calculation in another field or five an illusion of a negative value (when a positive value is entered) by formatting the field using -0 for the format property which can now be applied to a field in a table, query, form or report.
Hope this helped.
Ben Beitler
Your Access Expert!
ajetrumpet??YOUR??![]()
you may also want to limit what can be put into the field...or make an if statement and only process the code above if the value is >0.