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)


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

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


  • fileName
    Type: System.String

    The file name for the attachment to add.

Return value

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

See also


AttachmentCollection class

AttachmentCollection members

Add overload

Microsoft.Exchange.Data.Transport.Email namespace