Decimal form input

P

Pete

In Excel I can select a fixed decimal under Tools,
Options so I don't have to key in the decimal during
input. How do I set that feature in Access forms.
 
K

Ken Snell

I don't believe you can set this option. However, you can code the control
in the ACCESS form (using its AfterUpdate event) to automatically convert
the entered number to the desired decimal size:

Private Sub ControlName_AfterUpdate()
Me.ControlName.Value = Me.ControlName.Value / 10 ^ #
End Sub

where you replace # with the power of 10 that you want to use for dividing
the number to get to the decimal size. Be sure that the control is formatted
as General Number.
 

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