G
Guest
I have inherited the following code to send email:
--------------------------------------------------------
Private Sub btnMail_Click()
On Error GoTo ComposeErr
Dim strMessage As String
Dim objMessage As Object
Me.ctlMAPISession.UserName = gUserID
Me.ctlMAPISession.Password = gUserPassword
Me.ctlMAPISession.SignOn
Me.ctlMAPIMessage.SessionID = Me.ctlMAPISession.SessionID
Me.ctlMAPIMessage.Compose
Me.ctlMAPIMessage.MsgIndex = -1
Me.ctlMAPIMessage.RecipDisplayName = Trim(Me.txtemail.Text)
Me.ctlMAPIMessage.Send True
------- this is where Outlook is waiting for the user to compose the message
and hit “sendâ€.
Me.ctlMAPISession.SignOff
Exit Sub
ComposeErr:
' MsgBox Str(Err.Number) + " " + Err.Description
MsgBox Err.Description
Resume Next
End Sub
-------------------------------------------------------------------------
When the user presses the button to invoke this method, no signature appears
on the message and the user isn't able to switch to the Outlook window.
Does anyone know how to make the signature appear? Is this just old
technology?
--------------------------------------------------------
Private Sub btnMail_Click()
On Error GoTo ComposeErr
Dim strMessage As String
Dim objMessage As Object
Me.ctlMAPISession.UserName = gUserID
Me.ctlMAPISession.Password = gUserPassword
Me.ctlMAPISession.SignOn
Me.ctlMAPIMessage.SessionID = Me.ctlMAPISession.SessionID
Me.ctlMAPIMessage.Compose
Me.ctlMAPIMessage.MsgIndex = -1
Me.ctlMAPIMessage.RecipDisplayName = Trim(Me.txtemail.Text)
Me.ctlMAPIMessage.Send True
------- this is where Outlook is waiting for the user to compose the message
and hit “sendâ€.
Me.ctlMAPISession.SignOff
Exit Sub
ComposeErr:
' MsgBox Str(Err.Number) + " " + Err.Description
MsgBox Err.Description
Resume Next
End Sub
-------------------------------------------------------------------------
When the user presses the button to invoke this method, no signature appears
on the message and the user isn't able to switch to the Outlook window.
Does anyone know how to make the signature appear? Is this just old
technology?