如何修复运行时错误'-2147024809(80070057)'

时间:2019-06-13 09:40:43

标签: excel vba outlook outlook-vba

Sub getDataFromOutlook()

    Dim OutlookApp As Outlook.Application

    Dim OutlookNamespace As Namespace

    Dim Folder As MAPIFolder
    Dim OutlookMail As Variant

    Dim i As Integer

    Set OutlookApp = New Outlook.Application

    Set OutlookNamespace = OutlookApp.GetNamespace(“MAPI”)

    Set Folder = OutlookNamespace.GetDefaultFolder(olFolderInbox)

0 个答案:

没有答案