Email from an Access form with Groupwise

Henley12

Troy University Fan
Local time
Yesterday, 23:47
Joined
Oct 10, 2007
Messages
222
I am trying to send an email through Groupwise from an Access form. The code that follows works with one exception: it seems to have a limit to the number of characters it will send. Has anyone else experienced such a problem? Here is the code I am using.

Private Sub ConfigureHyperlink()
Dim emailAddress As String
Dim subject As String
Dim body As Variant

Const CRLF = "%0A"

'emailAddress = "name of recipient"
subject = "Help Desk Alert!!"

body = "*********** Call Alert!! ***********" & CRLF & CRLF
body = body & "Call ID: " & Me![CallID] & CRLF
body = body & "Caller: " & Me![LName] & ", " & Me![FName] & CRLF
body = body & "Phone: " & Me![Phone] & CRLF
body = body & "Department: " & Me![Dept] & CRLF & CRLF
body = body & "Description: " & Me![Description] & CRLF

mailingLabel.HyperlinkAddress = FormatEmail(emailAddress, subject, body)

End Sub

Private Function FormatEmail(emailAddress As String, _
subject As String, body As Variant)
' Format address, subject and body
' for use with HyperlinkAddress property:
FormatEmail = "mailto:" & emailAddress & _
"?Subject=" & subject & "&Body=" & body
End Function
 
The problem I have is with the DoCmd.SendObject command. It tells me "the command or action 'SendObject' isn't available now". We do not use Outlook or Outlook Express as our email system, but rather Groupwise. Any suggestions?
 
Take a look at this....
This is a stripped down version of what I am currently using and it works great.
Hope this helps
-Robert
 

Attachments

I am getting an 'Object doesn't support this property or method 438' error on the recipients statement. Any ideas?
 
Take a look at this....
This is a stripped down version of what I am currently using and it works great.
Hope this helps
-Robert


Robert,
Thanks for the code, but I had to modify it slightly (at least for Groupwise 7.0 )
It wasn't adding a recipient, thus it throws an error when it tries to send.
I modified as shown below and it works GREAT!!! So BIG THANKS

For others reference:
Code:
    With objMessage
        .Subject = Subject
        .Bodytext = strEMailMsg
        .Recipients.Add "sendtohere@hotmail.com"

    End With
PEACE,
Aaron
 
Last edited:

Users who are viewing this thread

Back
Top Bottom