Envoie Email Outlook Express. Comment passer L'Option Cc: ?

Roland_M

XLDnaute Barbatruc
bien le bonjour à tous,

je me sert d'Outlokk Express, tout va bien mais j'ai quelques difficultés avec l'option Cc:

ma question, quelle est le paramètre à mettre pour cette passer cette Option ou Paramètre ?

j'ai ceci qui est Ok (évidemment sans cette option Cc)

Opt = "/mailurl:mailto:" & EmailAdresDestinataire & "?subject=" & EmailSujet & "&Body=" & EmailMessage
Shell "C:\Program Files\Outlook Express\msimn.exe " & Opt
etc...



Merci d'avance
 

BERRACHED said

XLDnaute Accro
Re : Envoie Email Outlook Express. Comment passer L'Option Cc: ?

Salut,Roland M

tu peux t'inspirer de ce code :

Code:
Private Sub Application_ItemSend(ByVal Item As Object, _
 
Cancel As Boolean)
 
Dim myRecipient As Outlook.Recipient
 
If Not Item.Class = olMail Then GoTo fin
 
Dim prompt As String
 
' ici renseigner le destinataire
 
cci = "MonDestinataire@sonDomaine.fr"
 
'commentez au choix l'option non voulue
 
'########################Option CCI############################
 
prompt = "Ajouter le cci " & cci & " à " & Item.Subject & "?"
 
If MsgBox(prompt, vbYesNo + vbQuestion, "Sample") = vbYes Then
 
Set myRecipient = Item.Recipients.Add(cci)
 
myRecipient.Type = olBCC
 
myRecipient.Resolve
 
If myRecipient.Resolved = False Then
 
MsgBox "L'adresse Email n'est pas correcte !", vbCritical, "Erreur"
 
Cancel = True
End If
 
End If
 
'########################Option CC##############################
 
prompt = "Ajouter le cc " & cci & " à " & Item.Subject & "?"
 
If MsgBox(prompt, vbYesNo + vbQuestion, "Sample") = vbYes Then
 
Set myRecipient = Item.Recipients.Add(cci)
 
myRecipient.Type = olCC
 
myRecipient.Resolve
 
If myRecipient.Resolved = False Then
 
MsgBox "L'adresse Email n'est pas correcte !", vbCritical, "Erreur"
 
Cancel = True
End If
 
End If
 
'#######################FIN#####################################
 
fin:
 
End Sub

Cordialement
 

Statistiques des forums

Discussions
312 795
Messages
2 092 202
Membres
105 271
dernier inscrit
odevnet