Piloter outlook en vb.net

cs_chris81 Messages postés 589 Date d'inscription jeudi 2 octobre 2003 Statut Membre Dernière intervention 29 avril 2008 - 5 nov. 2004 à 12:39
 issemis - 7 août 2015 à 16:19
bonjour,

je cherche a piloter outllok depuis vb.net, en fait j'aimerai ouvrir la fenetre ("Nouveau message de outlook"), lui remplir les champs et lui mettre une piece jointe.
Pourriez me donner des pistes
merci

http://www.tarnweb.com
http://www.correzeweb.com
http://www.localetv.com

5 réponses

glplpmat Messages postés 70 Date d'inscription mercredi 11 juin 2003 Statut Membre Dernière intervention 2 octobre 2006 1
5 nov. 2004 à 13:36
glplpmat
0
glplpmat Messages postés 70 Date d'inscription mercredi 11 juin 2003 Statut Membre Dernière intervention 2 octobre 2006 1
5 nov. 2004 à 13:39
Exemple avec oitlook et exchserver

Sub SendMail(ByVal FromExp As String, ByVal AdrTO As String, ByVal sujet As String, ByVal corps As String, ByVal nomfich As String)
'send the email
If AdrTO = "" Then
AdrTO = "destinataire@xxx.com"
End If
If FromExp = "" Then
FromExp = "expediteur@xxx.com"
End If
Try
Dim insMail As New MailMessage()
With insMail
.From = FromExp
.To = AdrTO
'' .Cc = "concerne@xxx.com"
.Subject = sujet
.Body = corps
.Attachments.Add(New MailAttachment(Trim(nomfich)))
End With
SmtpMail.SmtpServer = "xxx.xxx.xxx.xxx" ' adresse du serveur
SmtpMail.Send(insMail)
Catch err As Exception
MessageBox.Show("Erreur dans procédure SendMail!", "SendMail", MessageBoxButtons.OK, MessageBoxIcon.Stop)
End Try
End Sub

glplpmat
0
cs_chris81 Messages postés 589 Date d'inscription jeudi 2 octobre 2003 Statut Membre Dernière intervention 29 avril 2008 2
5 nov. 2004 à 13:51
merci pour ce code mais je le connais deja, avec celui ci on ouvre pas de fenetre outlook, le mail part directement.
http://www.tarnweb.com
http://www.correzeweb.com
http://www.localetv.com
0
sgrant Messages postés 89 Date d'inscription mercredi 26 mai 2004 Statut Membre Dernière intervention 13 mai 2005 1
22 mars 2005 à 14:31
Bonjour,

est ce que vous avez trouvé la solution

Merci d'avance


sg
0

Vous n’avez pas trouvé la réponse que vous recherchez ?

Posez votre question
Bonjour,

j'aimerais bien avoir la solution.
merci
0
Rejoignez-nous