• General discussion

  • desse script abaixo algo necessita ser alterado para rodar no OUTLOOK 2016 - pois estava funcionando do 2013 e parou de rodar.

    Public Sub ProcessarAnexo(Email As MailItem)
         Dim DiretorioAnexos As String
         DiretorioAnexos = "C:\NFE"
         Dim MailID As String
         Dim Mail As Outlook.MailItem
         MailID = Email.EntryID
         Set Mail = Application.Session.GetItemFromID(MailID)
         For Each Anexo In Mail.Attachments
             If Right(Anexo.FileName, 3) = "xml" Then
                 Anexo.SaveAsFile DiretorioAnexos & "\" & Anexo.FileName
             End If
         Set Mail = Nothing
     End Sub
    Monday, October 9, 2017 7:48 PM

All replies

  • Hi Wafebar,

    Thank you for visiting our forum. 

    The forum that you posted is the English only forum for Microsoft Office. To avoid any misunderstanding that may be caused by the translation tool and better help you, please describe your issue in English. Alternatively, you could post this issue in other forums with the right language. 

    You can also contact the local support from the link below:


    Thanks for your cooperation and your understanding is greatly appreciated.

    Note: You can choose the right language by clicking the Change button from the left bottom of the page, and select the right product.

    Best Regards,
    Yuki Sun

    Please remember to mark the replies as answers if they helped.

    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    Tuesday, October 10, 2017 2:13 AM