EmailParser.Release
-------------------

Frees the email parser.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [EmailParser](component_EmailParser.md) | [5.3](newinversion53.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "EmailParser.Release"; EmailID ) 

**MBS**( **"EmailParser.Release";** /\* Frees the email parser. \*/  
**$EmailID**) /\* The ID fo the email parser.e.g. $Email \*/ 

(old name: EmailParser.Free)

### Parameters

| Parameter | Description | Example |
|---|---|---|
| EmailID | The ID fo the email parser. | $Email |

### Result

Returns OK or error.

### Description

Frees the email parser.  
Please call this function always with the reference numbers you got from [CURL.GetResultAsEmail](CURLGetResultAsEmail.md) or [EmailParser.Parse](EmailParserParse.md).  
### Examples

Parse Subject, PlainText and HTMLText from email:

 Set Variable \[$email ; Value:MBS ("[EmailParser.Parse](EmailParserParse.md)"; Email Parser::Input )\]  
If \[MBS ("IsError") = 1\]  
 Show Custom Dialog \["Failed to parse email."; Middle($email ; 7; Length($email ))\]  
 Exit Script \[\]  
End If  
\#Show text:   
Set Field \[Email Parser::Subject ; MBS ("[EmailParser.Subject](EmailParserSubject.md)"; $email )\]  
Set Field \[Email Parser::PlainText ; MBS ("[EmailParser.PlainText](EmailParserPlainText.md)"; $email )\]  
Set Field \[Email Parser::HTMLText ; MBS ("[EmailParser.HTMLText](EmailParserHTMLText.md)"; $email )\]  
\#cleanup   
Set Variable \[$r ; Value:MBS ("EmailParser.Release"; $email )\]  
### See also

- [CURL.GetResultAsEmail](CURLGetResultAsEmail.md)
- [CURL.GetResultAsMime](CURLGetResultAsMime.md)
- [EmailParser.Header](EmailParserHeader.md)
- [EmailParser.HTMLText](EmailParserHTMLText.md)
- [EmailParser.Parse](EmailParserParse.md)
- [EmailParser.PlainText](EmailParserPlainText.md)
- [EmailParser.ReleaseAll](EmailParserReleaseAll.md)
- [EmailParser.SentDate](EmailParserSentDate.md)
- [EmailParser.Subject](EmailParserSubject.md)
- [IsError](IsError.md)

### Release notes

- **Version 14.3**
    - Added [EmailParser.ReleaseAll](https://www.mbsplugins.eu/EmailParserReleaseAll.shtml) function.
    - Renamed [EmailParser.Free](https://www.mbsplugins.eu/EmailParserRelease.shtml) to [EmailParser.Release](https://www.mbsplugins.eu/EmailParserRelease.shtml), but old name will stay valid.

### Example Databases

- [CURL/Email/Email Client](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/CURL/Email/Email%20Client.shtml#1ScriptAnchor_)
- [CURL/Email/Email Parser and Preview](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/CURL/Email/Email%20Parser%20and%20Preview.shtml#1ScriptAnchor_)
- [CURL/Email/Email Parser](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/CURL/Email/Email%20Parser.shtml#1ScriptAnchor_)
- [CURL/Email/IMAP Email](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/CURL/Email/IMAP%20Email.shtml#4ScriptAnchor_)
- [Drag and Drop/for Mac/DragTest Email](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Drag%20and%20Drop/for%20Mac/DragTest%20Email.shtml#3ScriptAnchor_)

### Blog Entries

- [MBS FileMaker Plugin, version 14.3pr1](https://www.mbsplugins.de/archive/2024-06-03/MBS_FileMaker_Plugin_version_1/monkeybreadsoftware_blog_filemaker)
- [MBS Plugin Advent calendar: 23 - MailParser](https://www.mbsplugins.de/archive/2023-12-23/MBS_Plugin_Advent_calendar_23_/monkeybreadsoftware_blog_filemaker)

This function checks for a license.

Created 24th September 2015 , last changed 23th May 2024

  
[EmailParser.ReceiveDate](EmailParserReceiveDate.md) - [EmailParser.ReleaseAll](EmailParserReleaseAll.md)

[HTML Version](EmailParserRelease.shtml)