deepbreath
04-30-2001, 08:47 AM
i am trying to put a check box on the form so that if user presses a button (for printing a report) that checkbox then is automatically and permanently checked (so that it is known that report has been printed atleast one). only way to check the box is by pressing button not directly.
can anyone help me
thanx
Fornatian
04-30-2001, 09:10 AM
If you have button that you press to the print the report. Open the button properties and go into the code behind the button(OnClick event).
You will see something like...
Dim stDocName As String
stDocName = "rptInvoiceReport"
DoCmd.OpenReport stDocName, acNormal
Add this line:
Me![MyCheckBoxName] = True
This will change the checkbox to ticked. if you don't want users to click it themselves set it's locked property to Yes.
If you have continuous forms set then this will only tick the box for the record with the focus.
Hope that helps a little.
Ian