Set theMail = Nothing Set olNS = Nothing Set objItem = Nothing End Sub == > à l'execution, rien ne se passe - pas de changement de format texte en html - pas de modification du body suivant les regex indiquées
merci Cordialement
Bonjour/soir,
Ci-dessous quelques modifs pour les erreurs de non déclaration de variables
et de "l'initialisation" à nothing d'un objet non existant.
En OL2K3 Regex, il ne connait pas!
Cordialement.
--->
Sub test()
Dim objItem, toBodyTag, strFinalBody, strID, olNS
Dim olMail As Outlook.MailItem
On Error Resume Next
Set objItem = Application.ActiveInspector.CurrentItem
' convert mail to html format
strID = objItem.EntryID
Set olNS = Application.GetNamespace("MAPI")
olMail = olNS.GetItemFromID(strID)
olMail.Save
Set olMail = Nothing
Set olNS = Nothing
Set objItem = Nothing
End Sub
<----
--
Grég
"julien Touche" <julien.touche@touche.fr.st> a écrit dans le message de
news: 45eaa50f$0$32299$426a74cc@news.free.fr...
Bonjour
est-ce que quelqu'un pourrait m'aider à trouver le pb dans cette macro ?
== > Sub test()
Dim objItem, toBodyTag, strFinalBody
Dim olMail As Outlook.MailItem
On Error Resume Next
Set objItem = Application.ActiveInspector.CurrentItem
' convert mail to html format
strID = objItem.EntryID
Set olNS = Application.GetNamespace("MAPI")
olMail = olNS.GetItemFromID(strID)
olMail.Save
Set theMail = Nothing
Set olNS = Nothing
Set objItem = Nothing
End Sub
== >
à l'execution, rien ne se passe
- pas de changement de format texte en html
- pas de modification du body suivant les regex indiquées
Set theMail = Nothing Set olNS = Nothing Set objItem = Nothing End Sub == > à l'execution, rien ne se passe - pas de changement de format texte en html - pas de modification du body suivant les regex indiquées
merci Cordialement
Geo
Évitez ceci :
On Error Resume Next
A vous aidera à comprendre ce qui se passe dans votre macro.
-- A+
Évitez ceci :
On Error Resume Next
A vous aidera à comprendre ce qui se passe dans votre macro.