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
MessageBody(string)
Initializes a new instance of the MessageBody class.
public MessageBody(string text)
Parameters
text
stringThe 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
Text
Gets or sets the text of the message body.
public string Text { get; set; }
Property Value
Methods
ToString()
public override string ToString()
Returns
Operators
implicit operator string(MessageBody)
Defines an implicit conversion of MessageBody into a string.
public static implicit operator string(MessageBody messageBody)
Parameters
messageBody
MessageBodyThe 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
stringThe string to convert to MessageBody, assumed to be HTML.
Returns
- MessageBody
A MessageBody initialized with the specified string.