MailMessage.CC プロパティとは? わかりやすく解説

MailMessage.CC プロパティ

メモ : このプロパティは、.NET Framework version 2.0新しく追加されたものです。

この電子メール メッセージCC (carbon copy) 受信者を格納するアドレスコレクション取得します

名前空間: System.Net.Mail
アセンブリ: System (system.dll 内)
構文構文

Public ReadOnly Property
 CC As MailAddressCollection
Dim instance As MailMessage
Dim value As MailAddressCollection

value = instance.CC
public MailAddressCollection CC { get; }
public:
property MailAddressCollection^ CC {
    MailAddressCollection^ get ();
}
/** @property */
public MailAddressCollection get_CC ()
public function get CC ()
 : MailAddressCollection

プロパティ
書き込み可能な MailAddressCollection オブジェクト

解説解説
使用例使用例

アドレスCC アドレスコレクション追加するコード例次に示します

public static void CreateCopyMessage(string
 server)
{
    MailAddress from = new MailAddress("ben@contoso.com",
 "Ben Miller");
    MailAddress to = new MailAddress("jane@contoso.com",
 "Jane Clayton");
    MailMessage message = new MailMessage(from, to);
    // message.Subject = "Using the SmtpClient class.";
    message.Subject = "Using the SmtpClient class.";
    message.Body = @"Using this feature, you can send an
 e-mail message from an application very easily.";
    // Add a carbon copy recipient.
    MailAddress copy = new MailAddress("Notification_List@contoso.com");
    message.CC.Add(copy);
    SmtpClient client = new SmtpClient(server);
    // Include credentials if the server requires them.
    client.Credentials = CredentialCache.DefaultNetworkCredentials;
    Console.WriteLine("Sending an e-mail message to {0} by using
 the SMTP host {1}.",
         to.Address, client.Host);
    client.Send(message);
}
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
MailMessage クラス
MailMessage メンバ
System.Net.Mail 名前空間

MailMessage.Cc プロパティ

CC (カーボン コピー) を受信する電子メール アドレスを、セミコロン区切りリスト取得または設定します推奨する代替 : System.Net.Mail

名前空間: System.Web.Mail
アセンブリ: System.Web (system.web.dll 内)
構文構文

解説解説
使用例使用例
Dim MyMessage As MailMessage = New
 MailMessage()
MyMessage.Cc = "fred@contoso.com"
MailMessage MyMessage = new MailMessage();
MyMessage.Cc = "fred@contoso.com";
MailMessage myMessage = new MailMessage();
myMessage.set_Cc("fred@contoso.com");
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
MailMessage クラス
MailMessage メンバ
System.Web.Mail 名前空間



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「MailMessage.CC プロパティ」の関連用語

MailMessage.CC プロパティのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



MailMessage.CC プロパティのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2024 Microsoft.All rights reserved.

©2024 GRAS Group, Inc.RSS