A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Redemption - multiple emails for cc - error: could not resolve ema



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old August 27th 07, 04:16 PM posted to microsoft.public.outlook.program_vba
Sam
external usenet poster
 
Posts: 143
Default Redemption - multiple emails for cc - error: could not resolve ema

Hi

I am using Redemption in my VBA(in Microsoft Access) to send email via
outlook. I have a (Access) form that has two textboxes, one for To and one
for CC. the To has one email address, and the cc had two or three email
addresses. I get an error "could not resolve email address..." if i have more
than one email address. i use a semi-colon to seperate email addresses, and i
end the last email address with a semi colon.

can someone tell me what i can do to resolve this?

thanks,

Sam
  #2  
Old August 27th 07, 04:35 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Redemption - multiple emails for cc - error: could not resolve ema

Use the Recipients collection of the item and add each Recipient object one
at a time. To set them as To or Cc use Recipient.Type = olTo or
Recipient.Type = olCC.

When you add a Recipient object you can then resolve it and test for
success:

Dim oRecip As Outlook.Recipient
Dim colRecips As Outlook.Recipients

Set colRecips = item.Recipients
Set oRecip = colRecips.Add("some email address")
If Not (oRecip Is Nothing) Then
oRecip.Type = olTo
oRecip.Resolve
If Not oRecip.Resolved Then
MsgBox "Could not resolve recipient " & "some email address"
End If
End If

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"SAm" wrote in message
...
Hi

I am using Redemption in my VBA(in Microsoft Access) to send email via
outlook. I have a (Access) form that has two textboxes, one for To and one
for CC. the To has one email address, and the cc had two or three email
addresses. I get an error "could not resolve email address..." if i have
more
than one email address. i use a semi-colon to seperate email addresses,
and i
end the last email address with a semi colon.

can someone tell me what i can do to resolve this?

thanks,

Sam


  #3  
Old August 27th 07, 07:40 PM posted to microsoft.public.outlook.program_vba
Sam
external usenet poster
 
Posts: 143
Default Redemption - multiple emails for cc - error: could not resolve

Thanks,

I used the split function and a for loop to go through all of the email
addresses. now it works fine.

sam


"Ken Slovak - [MVP - Outlook]" wrote:

Use the Recipients collection of the item and add each Recipient object one
at a time. To set them as To or Cc use Recipient.Type = olTo or
Recipient.Type = olCC.

When you add a Recipient object you can then resolve it and test for
success:

Dim oRecip As Outlook.Recipient
Dim colRecips As Outlook.Recipients

Set colRecips = item.Recipients
Set oRecip = colRecips.Add("some email address")
If Not (oRecip Is Nothing) Then
oRecip.Type = olTo
oRecip.Resolve
If Not oRecip.Resolved Then
MsgBox "Could not resolve recipient " & "some email address"
End If
End If

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"SAm" wrote in message
...
Hi

I am using Redemption in my VBA(in Microsoft Access) to send email via
outlook. I have a (Access) form that has two textboxes, one for To and one
for CC. the To has one email address, and the cc had two or three email
addresses. I get an error "could not resolve email address..." if i have
more
than one email address. i use a semi-colon to seperate email addresses,
and i
end the last email address with a semi colon.

can someone tell me what i can do to resolve this?

thanks,

Sam



 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
how do i resolve 553 smtp error in outlook 2003 absolute office Outlook - Installation 1 July 7th 07 03:51 PM
absolutely cannot resolve timeout error stef Outlook - Installation 12 September 27th 06 01:51 AM
absolutely cannot resolve timeout error stef Outlook - General Queries 4 September 23rd 06 09:13 PM
How do I resolve desktop error code 85010014? Mia Outlook and VBA 0 June 15th 06 04:31 PM
How to resolve error message 0X8004210A grneyeldy1966 Outlook - Installation 1 March 29th 06 04:32 AM


All times are GMT +1. The time now is 02:46 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.