大家有没有做过读取outlook收件箱邮件内容的?!!!
我想读取outlook收件箱邮件内容,并且存入excel
大家有这方面的建议么,谢谢

解决方案 »

  1.   

    give me some suggestion
      

  2.   

    Public Sub ChkMail()
        Dim golApp As Outlook.Application
        Dim gnspNameSpace As Outlook.NameSpace
        Dim fldInbox As Outlook.MAPIFolder
        Dim i As Integer    Set golApp = ThisOutlookSession
        Set gnspNameSpace = golApp.GetNamespace("MAPI")
        Set fldInbox = gnspNameSpace.GetDefaultFolder(olFolderInbox)
        For i = 1 To fldInbox.Items.Count
            With fldInbox.Items.Item(i)
            '--write you code to get body,subject etc.        End With
        Next