Link to home
Create AccountLog in
Avatar of Andreas Hermle
Andreas HermleFlag for Germany

asked on

DCount field to be updated immediately

Dear Experts:

I got an unbound text field on a form ...
.. that displays the number of occurrences in which the checkbox (chkAuthor) is checked off.

=DCount("[chkAuthor]";"tblArticle";"[chkAuthor]<>0")

It works correctly. How can I get Access to UPDATE this form field IMMEDIATELY after I have checked off another checkbox (chkAuthor).
Now I often have to move thru several records in the form till this field gets updated.

Help is much appreciated. Thank you very much in advance.

Regards, Andreas
SOLUTION
Avatar of als315
als315
Flag of Russian Federation image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
DCount, of course
SOLUTION
Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
ASKER CERTIFIED SOLUTION
Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of Andreas Hermle

ASKER

Dear cactus_data and als315:

thank you very much for your swift help. It works just fine but only if I put your snippet into the 'Form_Current' Procedure. The AfterUpdate event does not work with me. Maybe you got my question wrong.

Buy anyhow thank you very much for your great help with this code snippet.

Hi fyed: no it is not a continuous form. Should I use one in the future your code  snippet will come in handy.

Regards, Andreas
I meant the AfterUpdate event of the checkbox you check off.

/gustav
Hi gustav,

ok, got it.

Thank you very much for your professional help.

Regards, Andreas
Dear all,

it is always very hard for me to award points equitably since I can learn from every answer.

Again, thank you very much for your time taken and the valuable / professional help.

Regards, Andreas
You are welcome!

/gustav