Check Box problem

elsanto

Aspiring to Sainthood...
Local time
Tomorrow, 08:23
Joined
Jul 9, 2003
Messages
35
Hey all,

I'm reluctant to post such a basic question, so apologies beforehand. But I've spent a good 40mins prowling through the forum and I can't find the info I'm after.

I have a table with multiple transactions per staff member.
I need to create a form that has a check box for each staff member - or some sort of multiple selection device - that I can use to preview a report.

ie., if checkbox Bill, Bob, Joe, and Suzie are selected, the report prints with records for Bill, Bob, Joe, and Suzie and no-one else.

Any ideas? I'm out.
Thanks.
 
Add a 'Yes/No field to your main table and call it 'SelectToPrint'. In the form, add the CheckBox. In the OnClick event of a button type...
Code:
    DoCmd.RunCommand acCmdSaveRecord
    stDocName = "NameOfYourReport"
    DoCmd.OpenReport stDocName, acPreview, "ID = '" & Me.SelectToPrint & "'"
NameOfYourReport being your report and ID being the ID of the table.

Hope this helps

IMO
 

Users who are viewing this thread

Back
Top Bottom