a calculating expression in an Access form

tnissley

New Member
Joined
May 3, 2003
Messages
10
I have an Access form which is based upon a query. the form has students name and a checkbox next to each name. The checkbox is based upon the query and the default is no. When I check the box next to a student's name, I want to be able to count the number of Checkboxes in each column. I've used the formula =Count (Iif([Attendance]="yes",1,0)). When I do that I get an error message. What am I doing wrong. Attendance is the field created in the table as a checkbox.
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
Hi, I'm a bit new to this myself, but since no one has responded yet, you could give this a try.

In the query you made for the form, type Present:IIf([Attendance],1) in the field box in a new column and run the query. You should see a new field named Present.

Open your form in design view and add a text box.
In the properties for the text box, type =Count([Present]) in the control source.

Hope this helps.

Gordon.
 
Upvote 0

Forum statistics

Threads
1,221,539
Messages
6,160,413
Members
451,644
Latest member
hglymph

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top