I used the following command to open a table and go to a specific record:
DoCmd.OpenTable "Donation Times"
Docmd.GoToRecord acDataTable, "Donation Times", acGoTo, 10
This works fine, but now that I am at the correct record, I want to change one of the fields. I tried the following, but I get the message can't find the field referred to in your expression.
If [Donation Times]!Donor2 = -1 then
[Donation Times]!Donor2 = 0
Else
[Donation Times]!Donor1 = 0
Endif
If I change the If statement to just the field name, I don't get the error, but the field doesn't change. Any suggestions would be appreciated.
DoCmd.OpenTable "Donation Times"
Docmd.GoToRecord acDataTable, "Donation Times", acGoTo, 10
This works fine, but now that I am at the correct record, I want to change one of the fields. I tried the following, but I get the message can't find the field referred to in your expression.
If [Donation Times]!Donor2 = -1 then
[Donation Times]!Donor2 = 0
Else
[Donation Times]!Donor1 = 0
Endif
If I change the If statement to just the field name, I don't get the error, but the field doesn't change. Any suggestions would be appreciated.