MessagePropertyFilter.AttachSenderId プロパティ

定義

メッセージを受信またはピークするときに AttachSenderId プロパティ情報を取得するかどうかを示す値を取得または設定します。

public:
 property bool AttachSenderId { bool get(); void set(bool value); };
[System.Messaging.MessagingDescription("MsgAttachSenderId")]
public bool AttachSenderId { get; set; }
[<System.Messaging.MessagingDescription("MsgAttachSenderId")>]
member this.AttachSenderId : bool with get, set
Public Property AttachSenderId As Boolean

プロパティ値

AttachSenderId 情報を受信する場合は true。それ以外の場合は false。 既定値は、false です。

属性

次のコード例では、 プロパティの使用方法を AttachSenderId 示します。

// Set the queue's MessageReadPropertyFilter property 
// to enable the message's AttachSenderId property.
queue->MessageReadPropertyFilter->AttachSenderId = true;

// Peek at the message. Time out after ten seconds 
// in case the message was not delivered.
orderMessage = queue->Peek(TimeSpan::FromSeconds(10.0));

// Display the value of the message's 
// AttachSenderId property.
Console::WriteLine("Message.AttachSenderId: {0}", 
    orderMessage->AttachSenderId);
// Set the queue's MessageReadPropertyFilter property to enable the
// message's AttachSenderId property.
queue.MessageReadPropertyFilter.AttachSenderId = true;

// Peek at the message. Time out after ten seconds in case the message
// was not delivered.
orderMessage = queue.Peek(TimeSpan.FromSeconds(10.0));

// Display the value of the message's AttachSenderId property.
Console.WriteLine("Message.AttachSenderId: {0}",
    orderMessage.AttachSenderId);

注釈

クラスの プロパティは AttachSenderId 、 を Message メッセージに添付するか、または添付するかを指定 Message.SenderId します。 Message.SenderIdはメッセージ キューによって設定され、送信側がキューへのアクセス権を持っているかどうかを確認するために、受信キュー マネージャーによって使用されます。

適用対象

こちらもご覧ください