Share via


AttachmentCollection.Add method (String)

The Add method adds a new Attachment object to the collection by using the file name specified by the fileName parameter.

Namespace:  Microsoft.Exchange.Data.Transport.Email
Assembly:  Microsoft.Exchange.Data.Transport (in Microsoft.Exchange.Data.Transport.dll)

Syntax

'Declaration
Public Function Add ( _
    fileName As String _
) As Attachment
'Usage
Dim instance As AttachmentCollection
Dim fileName As String
Dim returnValue As Attachment

returnValue = instance.Add(fileName)
public Attachment Add(
    string fileName
)

Parameters

  • fileName
    Type: System.String

    The file name for the attachment to add.

Return value

Type: Microsoft.Exchange.Data.Transport.Email.Attachment

See also

Reference

AttachmentCollection class

AttachmentCollection members

Add overload

Microsoft.Exchange.Data.Transport.Email namespace