Hi everyone -
I'm working with Access 2000 and Netscape Communicator 4.77 as my email tool.
I was trying to generate an email message using SendObject, and I was occasionally getting the following error:
Error # 2958 , Description: "Reserved Error"
Through a lot of trial and error, I realized that the error is being caused by what I put into the email address field.
If the string in the "To" field is 3 characters or less (any combination of letters, numbers, spaces or special characters), the email is created okay. However...
If the string in the "To" field is 4 characters or more (again, any combination of characters), I get the #2958 error, and the email is not generated.
My code is as follows:
If IsNull([Forms]![event builder]![contact person].Column(2)) Then
strEmail = " "
Else
' strEmail = [Forms]![event builder]![contact person].Column(2)
strEmail = "a@bc" 'for testing purposes
End If
DoCmd.SendObject , , acFormatHTML, strEmail, , , "Media Services Confirmation", strMessage, True
_______________________________________________
The "not null" situation is the one causing a problem. As you can see by my commented code, I want to pull the email address from a form. But if the length of the address is more than 3 characters (which of course they all are, if they exist), I get the error.
Can anyone tell me why I'm getting this? Could it have something to do with the fact that we use Netscape here instead of Outlook (which I can see most of the people in this forum use)?
By the way, I have to use an outputformat of acFormatHTML, due to a problem I was having with carriage control characters in the email message (see thread705-389549). I still get the same error if I change the outputformat to either acFormatTXT or acFormatRTF.
Thanks for any help you can offer...
- Anita
I'm working with Access 2000 and Netscape Communicator 4.77 as my email tool.
I was trying to generate an email message using SendObject, and I was occasionally getting the following error:
Error # 2958 , Description: "Reserved Error"
Through a lot of trial and error, I realized that the error is being caused by what I put into the email address field.
If the string in the "To" field is 3 characters or less (any combination of letters, numbers, spaces or special characters), the email is created okay. However...
If the string in the "To" field is 4 characters or more (again, any combination of characters), I get the #2958 error, and the email is not generated.
My code is as follows:
If IsNull([Forms]![event builder]![contact person].Column(2)) Then
strEmail = " "
Else
' strEmail = [Forms]![event builder]![contact person].Column(2)
strEmail = "a@bc" 'for testing purposes
End If
DoCmd.SendObject , , acFormatHTML, strEmail, , , "Media Services Confirmation", strMessage, True
_______________________________________________
The "not null" situation is the one causing a problem. As you can see by my commented code, I want to pull the email address from a form. But if the length of the address is more than 3 characters (which of course they all are, if they exist), I get the error.
Can anyone tell me why I'm getting this? Could it have something to do with the fact that we use Netscape here instead of Outlook (which I can see most of the people in this forum use)?
By the way, I have to use an outputformat of acFormatHTML, due to a problem I was having with carriage control characters in the email message (see thread705-389549). I still get the same error if I change the outputformat to either acFormatTXT or acFormatRTF.
Thanks for any help you can offer...
- Anita