Table of Contents

Class MessageBody

Namespace
Microsoft.Exchange.WebServices.Data
Assembly
Microsoft.Exchange.WebServices.dll

Represents the body of a message.

public class MessageBody : ComplexProperty
Inheritance
MessageBody
Derived
Inherited Members

Constructors

MessageBody()

Initializes a new instance of the MessageBody class.

public MessageBody()

MessageBody(BodyType, string)

Initializes a new instance of the MessageBody class.

public MessageBody(BodyType bodyType, string text)

Parameters

bodyType BodyType

The type of the message body's text.

text string

The text of the message body.

MessageBody(string)

Initializes a new instance of the MessageBody class.

public MessageBody(string text)

Parameters

text string

The text of the message body, assumed to be HTML.

Properties

BodyType

Gets or sets the type of the message body's text.

public BodyType BodyType { get; set; }

Property Value

BodyType

Text

Gets or sets the text of the message body.

public string Text { get; set; }

Property Value

string

Methods

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.

Operators

implicit operator string(MessageBody)

Defines an implicit conversion of MessageBody into a string.

public static implicit operator string(MessageBody messageBody)

Parameters

messageBody MessageBody

The MessageBody to convert to a string.

Returns

string

A string containing the text of the MessageBody.

implicit operator MessageBody(string)

Defines an implicit conversation between a string and MessageBody.

public static implicit operator MessageBody(string textBody)

Parameters

textBody string

The string to convert to MessageBody, assumed to be HTML.

Returns

MessageBody

A MessageBody initialized with the specified string.