dmyoungsal
Registered User.
- Local time
- Today, 02:17
- Joined
- May 1, 2016
- Messages
- 112
In my database, I have a screen that users enter data into and once complete, they click a button to do a Print Preview. If all is good, they can click the print button and the report will print.
It works fine on my computer, but all my users that are using the Access 2013 R/T and when they click Print (from the Print Preview screen), the database closes.
Here is the code for printing when a new entry is made:
Private Sub Command376_Click()
Dim strDocName As String
Dim strWhere As String
strDocName = "rptTransCalcTruckNew"
strWhere = "[ID]=" & Me!txtID
DoCmd.OpenReport strDocName, acPreview, , strWhere
End Sub
Here is the code for printing from the Inquiry screen:
Private Sub Command118_Click()
Dim strDocName As String
Dim strWhere As String
strDocName = "rptTransCalcTruck"
strWhere = "[ID]=" & Me!txtID
DoCmd.OpenReport strDocName, acPreview, , strWhere
End Sub
It works fine on my computer, but all my users that are using the Access 2013 R/T and when they click Print (from the Print Preview screen), the database closes.
Here is the code for printing when a new entry is made:
Private Sub Command376_Click()
Dim strDocName As String
Dim strWhere As String
strDocName = "rptTransCalcTruckNew"
strWhere = "[ID]=" & Me!txtID
DoCmd.OpenReport strDocName, acPreview, , strWhere
End Sub
Here is the code for printing from the Inquiry screen:
Private Sub Command118_Click()
Dim strDocName As String
Dim strWhere As String
strDocName = "rptTransCalcTruck"
strWhere = "[ID]=" & Me!txtID
DoCmd.OpenReport strDocName, acPreview, , strWhere
End Sub