N
NicoleDBS
I have written some code that works, but I need to have the form clear the
current record after printing the current record. I was getting an error
message that said I was creating dupes, but was able to fix that by removing
the PK and having it indexed with duplicates okay. Please take a look at the
code and let me know what else needs to be done to clear the form.
THANKS in advance.
Private Sub Command106_Click()
On Error GoTo Err_Command106_Click
Dim stDocName As String
Dim MyForm As Form
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.PrintOut acSelection
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
DoCmd.GoToRecord , stDocName, acNewRec
Exit_Command106_Click:
Exit Sub
Err_Command106_Click:
MsgBox Err.Description
Resume Exit_Command106_Click
End Sub
current record after printing the current record. I was getting an error
message that said I was creating dupes, but was able to fix that by removing
the PK and having it indexed with duplicates okay. Please take a look at the
code and let me know what else needs to be done to clear the form.
THANKS in advance.
Private Sub Command106_Click()
On Error GoTo Err_Command106_Click
Dim stDocName As String
Dim MyForm As Form
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.PrintOut acSelection
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
DoCmd.GoToRecord , stDocName, acNewRec
Exit_Command106_Click:
Exit Sub
Err_Command106_Click:
MsgBox Err.Description
Resume Exit_Command106_Click
End Sub