Results 1 to 2 of 2
2002-12-19, 20:03 #1
- Join Date
- Oct 2001
- New York
- Thanked 0 Times in 0 Posts
Overwriting a field? (Access 97 SR1)
I need to create a field in my database called settlement amount. The user would like the amount to show the amount from a field entitled ScheduledAmt, however, sometimes the settlement amount might be different, and he would like to be able to overwrite that amount if it does not equal ScheduledAmt. How do I do that?
2002-12-19, 22:45 #2
- Join Date
- Jun 2002
- Mt Macedon, Victoria, Australia
- Thanked 45 Times in 44 Posts
Re: Overwriting a field? (Access 97 SR1)
You need to have both fields in the table.
Then on the form where the data entry is taking place, write an after update event for the ScheduledAmt field.
if isNull(me!settlementamount) then
me!settlementamount = me!ScheduledAmt
What will happen is that the moment anything is entered into Scheduledamt the same figure will appear in settlement amt, but you can then overwrite it if you wish.
The reason for the if isNull( ) stuff is so that if you subsequently change the scheduleamt, it doesn't overwrite again. I don't know if you really want or need this bit.Regards