Twain.SetCloseAfterTransfer
---------------------------

Whether to close window and data source after a transfer.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Twain](component_Twain.md) | [3.1](newinversion31.md) | ✅ Yes | ✅ Yes | ❌ No | ❌ No | ❌ No |

MBS( "Twain.SetCloseAfterTransfer"; Value ) 

**MBS**( **"Twain.SetCloseAfterTransfer";** /\* Whether to close window and data source after a transfer. \*/  
**$Value**) /\* The new settings. Can be 1 to closing or 0 to disable. Default is 0.e.g. 0 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| Value | The new settings. Can be 1 to closing or 0 to disable. Default is 0. | 0 |

### Result

Returns OK.

### Description

Whether to close window and data source after a transfer.  
GUI is only closed when being used.  
### Examples

Set options and acquire:

 $r = MBS ( "Twain.SetCloseAfterTransfer"; 1 )  
$r = MBS ( "[Twain.SetFeededEnabled](TwainSetFeededEnabled.md)"; 1 )  
$r = MBS ( "[Twain.SetAutofeed](TwainSetAutofeed.md)"; 1 )  
$r = MBS ( "[Twain.Acquire](TwainAcquire.md)" )  
### See also

- [Twain.Acquire](TwainAcquire.md)
- [Twain.GetCloseAfterTransfer](TwainGetCloseAfterTransfer.md)
- [Twain.SetAutofeed](TwainSetAutofeed.md)
- [Twain.SetFeededEnabled](TwainSetFeededEnabled.md)

### Example Databases

- [Win Only/Scanning/Twain](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Win%20Only/Scanning/Twain.shtml#8ScriptAnchor_)

### Blog Entries

- [MBS Filemaker Plugin, version 3.2pr4](https://www.mbsplugins.de/archive/2013-03-18/MBS_Filemaker_Plugin_version_3/monkeybreadsoftware_blog_filemaker)

This function is free to use.

Created 18th August 2014 , last changed 18th August 2014

  
[Twain.SetCancelScript](TwainSetCancelScript.md) - [Twain.SetCompressionQuality](TwainSetCompressionQuality.md)

[HTML Version](TwainSetCloseAfterTransfer.shtml)