All,
I have the following code below that is behind a command button on a form. Once the email comes up and they decide not to send the email and close the outlook message, it will give an error message.
I would like to suppress that error message by using the following:
DoCmd.SetWarnings True
DoCmd.SetWarnings False
but it is not working. The DoCmd.SetWarnings True is before the SendObject code and the DoCmd.SetWarnings False is after the SendObject code.
Does anyone know why this wouldn't work?
Please help.
Thank you all very much.
Dim strSubject As String
strSubject = Me.title
DoCmd.SendObject acSendReport, "rpt_PAF_GenUserEmail", acFormatSNP, "", "email@anywhere.com", , strSubject, "Subject Line Text Here.", False
The above code is behind a command button on a switchboard.
I have a table that has a date field. It is on a form called frmTest. I would like to be able to include that date field on the strSubject line.
Something like this:
strSubject = The email is sent as of [Forms]![frmTest]![date].Value
I know that is wrong. Can someone help me with this?
Jerome Benton
JERPAT Web Designs
GOD Is Good All The Time!!!
I have the following code below that is behind a command button on a form. Once the email comes up and they decide not to send the email and close the outlook message, it will give an error message.
I would like to suppress that error message by using the following:
DoCmd.SetWarnings True
DoCmd.SetWarnings False
but it is not working. The DoCmd.SetWarnings True is before the SendObject code and the DoCmd.SetWarnings False is after the SendObject code.
Does anyone know why this wouldn't work?
Please help.
Thank you all very much.
Dim strSubject As String
strSubject = Me.title
DoCmd.SendObject acSendReport, "rpt_PAF_GenUserEmail", acFormatSNP, "", "email@anywhere.com", , strSubject, "Subject Line Text Here.", False
The above code is behind a command button on a switchboard.
I have a table that has a date field. It is on a form called frmTest. I would like to be able to include that date field on the strSubject line.
Something like this:
strSubject = The email is sent as of [Forms]![frmTest]![date].Value
I know that is wrong. Can someone help me with this?
Jerome Benton
JERPAT Web Designs
GOD Is Good All The Time!!!