EmailAttachment 构造函数

定义

重载

EmailAttachment(FileBase)

基于FileBase对象初始化类的新实例EmailAttachment

EmailAttachment(String)

根据所提供的路径中指定的文件初始化类的新实例 EmailAttachment

EmailAttachment(String, String)

根据提供的路径中指定的文件以及提供显式 MIME 文件类型初始化类的新实例 EmailAttachment

EmailAttachment(FileBase)

Source:
Email.shared.cs
Source:
Email.shared.cs

基于FileBase对象初始化类的新实例EmailAttachment

public:
 EmailAttachment(Microsoft::Maui::Storage::FileBase ^ file);
public EmailAttachment (Microsoft.Maui.Storage.FileBase file);
new Microsoft.Maui.ApplicationModel.Communication.EmailAttachment : Microsoft.Maui.Storage.FileBase -> Microsoft.Maui.ApplicationModel.Communication.EmailAttachment
Public Sub New (file As FileBase)

参数

file
FileBase

包含文件信息的实例 FileBase

适用于

EmailAttachment(String)

Source:
Email.shared.cs
Source:
Email.shared.cs

根据所提供的路径中指定的文件初始化类的新实例 EmailAttachment

public:
 EmailAttachment(System::String ^ fullPath);
public EmailAttachment (string fullPath);
new Microsoft.Maui.ApplicationModel.Communication.EmailAttachment : string -> Microsoft.Maui.ApplicationModel.Communication.EmailAttachment
Public Sub New (fullPath As String)

参数

fullPath
String

文件系统上文件的完整路径和文件名。

适用于

EmailAttachment(String, String)

Source:
Email.shared.cs
Source:
Email.shared.cs

根据提供的路径中指定的文件以及提供显式 MIME 文件类型初始化类的新实例 EmailAttachment

public:
 EmailAttachment(System::String ^ fullPath, System::String ^ contentType);
public EmailAttachment (string fullPath, string contentType);
new Microsoft.Maui.ApplicationModel.Communication.EmailAttachment : string * string -> Microsoft.Maui.ApplicationModel.Communication.EmailAttachment
Public Sub New (fullPath As String, contentType As String)

参数

fullPath
String

文件系统上文件的完整路径和文件名。

contentType
String

文件的内容类型(MIME 类型),例如: image/png

适用于