Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 34
Default Email using Lotus Notes & FollowHyperlink

Hi Andy,

I'm familiar with that code, having seen it in other threads in the
Excel.programming newsgroup. Unfortunately, I have no way of determining the
default e-mail client. I tried using Application.MailSystem, but it does not
work (returns a value of "1", same as xlMAPI).

I would consider using CDO (see Ron de Bruin's site), but would need to find
a way to locate the SMTP server for each user (this application will be run
across several networks).

I've snipped out the original code I presented earlier and will try to
restate my request. I have two sets of code designed to launch an e-mail
event using Application.FollowHyperlink. Both build a "mailto" string and
both work with MS Outlook. However, only the second one works with Lotus
Notes. Does anyone see a reason why the first one would not work with Lotus
Notes (ex. in a userform module?)

=======First Routine (does not work with Lotus Notes)========
Private Sub btnSend_Click()
boolRej = True
If frmRejectEmail.chSuprCC.Value = True Then
If Range("SuprEmail").Value = Range("UserEmail").Value Then
sAddedtext = "&BCC=" & Range("SuprEmail").Value
Else
sAddedtext = "&CC=" & Range("SuprEmail").Value
sAddedtext = sAddedtext & "&BCC=" & Range("UserEmail").Value
End If
End If
sAddedtext = sAddedtext & "&Subject=" & frmRejectEmail.lblSubject.Caption
sAddedtext = sAddedtext & "&Body=" & frmRejectEmail.lblDefaultMsg.Caption
If frmRejectEmail.txtMsgBody.Value < "" Then
sAddedtext = sAddedtext & " - " & frmRejectEmail.txtMsgBody.Value
End If

stext = "mailto:" & strEmail
Mid$(sAddedtext, 1, 1) = "?"
stext = stext & sAddedtext
ThisWorkbook.FollowHyperlink stext
frmRejectEmail.Hide
End Sub

======Second routine (works with Lotus Notes)======
Sub Send_mail2()
Dim chSuprCC As Boolean
Dim stext, sAddedtext As String
chSuprCC = True
If chSuprCC = True Then
sAddedtext = "&BCC=" & "
End If
sAddedtext = sAddedtext & "&Subject=" & "this is the subject"
sAddedtext = sAddedtext & "&Body=" & "you messed up and this is what
you're gonna do about it"
If "and another thing" < "" Then
sAddedtext = sAddedtext & " - " & vbCrLf & vbCrLf & "and another
thing: Don't ask questions"
End If

stext = "mailto:" & "
Mid$(sAddedtext, 1, 1) = "?"
stext = stext & sAddedtext
ThisWorkbook.FollowHyperlink stext
End Sub
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
lotus notes email pdaws Excel Worksheet Functions 2 October 2nd 08 04:08 PM
Why won't AOL email communicate with lotus notes email? ManInaMaze Excel Discussion (Misc queries) 0 August 3rd 05 02:41 AM
Lotus Notes/Export to email na Excel Programming 1 November 16th 04 09:14 PM
Automating email using Lotus Notes Will Francis Excel Programming 0 August 25th 03 10:56 AM
Sending Email using Lotus Notes Bob[_26_] Excel Programming 1 July 29th 03 07:31 PM


All times are GMT +1. The time now is 02:57 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"