簡體   English   中英

在 Excel 應用程序中創建 Outlook 項目生成錯誤:“對象不支持此屬性或方法”

[英]Creating Outlook Item in Excel Application generates error: “Object doesn't support this property or method”

下面是 Excel 宏的開頭。 我一直收到消息

“對象不支持此屬性或方法。

Sub RegisterAppointmentList(CName As String)

    ' adds a list of appontments to the Calendar in Outlook
    Dim olApp As Outlook.Application
    Dim olApptItem As Outlook.AppointmentItem

    Set olApp = GetObject("", "Outlook.Application")

    Set olApptItem = Application.CreateItem(olAppointmentItem)

    On Error Resume Next

換行

Set olApptItem = Application.CreateItem(olAppointmentItem)

Set olApptItem = olApp.CreateItem(olAppointmentItem)

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM