Default value equals same value in another field in the same table

A

Akilah

Is there a way to automatically populated a field when another field in the
same table gets a value. For example, I have the fields AMOUNT_DUE and
CURRENT_VALUE. When a value is placed in the AMOUNT_DUE field I want that
same value to automatically populate the CURRENT_VALUE field. Is that
possible without running a query or macro?

Thanks,
Akilah
 
A

Al Campagna

Akilah,
Well, usually Amount_Due is a calculated field (ex.=Price * Qty), but if
Amount_Due is entered manually, you would use the AfterUpdate event of
Amount_Due to...

Private Sub Amount_Due AfterUpdate()
Me.Current_Value = ' your calculation here...
End Sub

Or, create a Macro using SetValue to calculate Current_Value

But, if... given any Amount_Due value, if you can always recalculate
Current_Value (on the fly), then you shouldn't be storing Current_Value at
all.
--
hth
Al Campagna
Microsoft Access MVP
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."
 

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