コレクションに Attachment オブジェクトを追加します。
このメソッドは、ファイル用の新規 Attachment オブジェクトを作成して、コレクションの最後にオブジェクトを追加します。コレクションからアイテムを取得するには、Item メソッドを使用します。
VBScript
' This example assumes there is at least 1 attachment field ' associated with the record. set currentSession = GetSession set attachFields = AttachmentFields set attachField1 = attachFields.Item(0) set theAttachments = attachField1.Attachments If Not theAttachments.Add("c:¥attach1.txt", "Defect description") Then OutputDebugString "Error adding attachment to record." End If