Hi
I have been reading through the post to try to find the solution to my problem but after adding different chunks of code I always hit the same problem.
I am doing some work for a plumber who having completed his work needs to produce a printed copy of a landlords report ( from his vans printer) to the landlord and then needs to email a copy of that report to the letting agent.
I am nearly there but find that I can print the form OK but I get the whole database merged into an RTF form and emailed to the agent selected
I would like my report ---Landlord Report (immediate) saved in pdf format ( i have nitro pdf)
ID number is autogenerated by ----MasterID
I have the agents email address(es) held in ----agentemail
here are some more recent chunks of code tried
DoCmd.RunCommand acCmdSaveRecord
Dim stDocName As String
stDocName = "Landlord Report (immediate)"
DoCmd.SendObject acReport, stDocName, acFormatRTF, "myemail.co.uk", , , "work completed", "please find attached landlords report completed by me", True
Exit_Err_email_Click:
Exit Sub
End Sub
Me.Filter = "[Control Number]='" & Forms![frmUpdate Controls]![Control Number Combo] & "'"
Dim stDocName As String
stDocName = "Landlord Report (immediate)"
DoCmd.SendObject acReport, stDocName
thanks for your help
I have been reading through the post to try to find the solution to my problem but after adding different chunks of code I always hit the same problem.
I am doing some work for a plumber who having completed his work needs to produce a printed copy of a landlords report ( from his vans printer) to the landlord and then needs to email a copy of that report to the letting agent.
I am nearly there but find that I can print the form OK but I get the whole database merged into an RTF form and emailed to the agent selected
I would like my report ---Landlord Report (immediate) saved in pdf format ( i have nitro pdf)
ID number is autogenerated by ----MasterID
I have the agents email address(es) held in ----agentemail
here are some more recent chunks of code tried
DoCmd.RunCommand acCmdSaveRecord
Dim stDocName As String
stDocName = "Landlord Report (immediate)"
DoCmd.SendObject acReport, stDocName, acFormatRTF, "myemail.co.uk", , , "work completed", "please find attached landlords report completed by me", True
Exit_Err_email_Click:
Exit Sub
End Sub
Me.Filter = "[Control Number]='" & Forms![frmUpdate Controls]![Control Number Combo] & "'"
Dim stDocName As String
stDocName = "Landlord Report (immediate)"
DoCmd.SendObject acReport, stDocName
thanks for your help