WinSendMail.SetText
-------------------

Sets the text content.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [WinSendMail](component_WinSendMail.md) | [7.1](newinversion71.md) | ❌ No | ✅ Yes | ❌ No | ❌ No | ❌ No |

MBS( "WinSendMail.SetText"; WinSendMailRef; Text ) 

**MBS**( **"WinSendMail.SetText";** /\* Sets the text content. \*/  
**$WinSendMailRef**; /\* The email reference number obtained using WinSendMai.CreateEmail function.e.g. $Email \*/   
**$Text**) /\* The new text.e.g. "Hello World" \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| WinSendMailRef | The email reference number obtained using WinSendMai.CreateEmail function. | $Email |
| Text | The new text. | "Hello World" |

### Result

Returns OK or error.

### Description

Sets the text content.  
  
You can use [Text.MergeFields](TextMergeFields.md) to replace placeholders with values from variables, fields and expressions.  
### Examples

Set text:

 Set Variable \[ $r ; Value:MBS ( "WinSendMail.SetText"; $email ; Send::Text ) \]  
### See also

- [Text.MergeFields](TextMergeFields.md)
- [WinSendMail.CreateEmail](WinSendMailCreateEmail.md)
- [WinSendMail.GetText](WinSendMailGetText.md)
- [WinSendMail.SetFrom](WinSendMailSetFrom.md)
- [WinSendMail.SetSubject](WinSendMailSetSubject.md)

### Example Databases

- [Win Only/Send Email via Email Application](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Win%20Only/Send%20Email%20via%20Email%20Application.shtml#1ScriptAnchor_)

This function checks for a license.

Created 28th February 2017 , last changed 25th November 2019

  
[WinSendMail.SetSubject](WinSendMailSetSubject.md) - [Window.Activate](WindowActivate.md)

[HTML Version](WinSendMailSetText.shtml)