1
1encapdiva
Everyone,
I created a button that I want to print a receipt for a client everytime
they visit our clinic. It will print, but not the active record on my client
receipt tab. Any thoughts?
Here's the code I am using:
Private Sub PrintClientReceipt_Click()
On Error GoTo Err_PrintClientReceipt_Click
Dim stDocName As String
Dim MyForm As Form
stDocName = "Client Receipt"
Set MyForm = Screen.ActiveForm
DoCmd.SelectObject acForm, stDocName, True
DoCmd.PrintOut
DoCmd.SelectObject acForm, MyForm.Name, False
Exit_PrintClientReceipt_Click:
Exit Sub
Err_PrintClientReceipt_Click:
MsgBox Err.Description
Resume Exit_PrintClientReceipt_Click
End Sub
I created a button that I want to print a receipt for a client everytime
they visit our clinic. It will print, but not the active record on my client
receipt tab. Any thoughts?
Here's the code I am using:
Private Sub PrintClientReceipt_Click()
On Error GoTo Err_PrintClientReceipt_Click
Dim stDocName As String
Dim MyForm As Form
stDocName = "Client Receipt"
Set MyForm = Screen.ActiveForm
DoCmd.SelectObject acForm, stDocName, True
DoCmd.PrintOut
DoCmd.SelectObject acForm, MyForm.Name, False
Exit_PrintClientReceipt_Click:
Exit Sub
Err_PrintClientReceipt_Click:
MsgBox Err.Description
Resume Exit_PrintClientReceipt_Click
End Sub