Twain.SetFolderPath
-------------------

Sets the folder path for storing image files.

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

MBS( "Twain.SetFolderPath"; Path ) 

**MBS**( **"Twain.SetFolderPath";** /\* Sets the folder path for storing image files. \*/  
**$Path**) /\* The path to the folder to use for storing image files. If empty clears the file pathe.g. "/Users/cs/Desktop/" \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| Path | The path to the folder to use for storing image files. If empty clears the file path | "/Users/cs/Desktop/" |

### Result

Returns OK on success.

### Description

Sets the folder path for storing image files.  
If you set the path with this function, images are not available with the [Twain.CurrentImage](TwainCurrentImage.md) function and Twain.ImageCount returns always zero. But with [Twain.GetFilePaths](TwainGetFilePaths.md) you can learn where files have been stored.  
The path must end with a slash on Mac and a backslash on Windows.   
  
This function requires a native path. Use [Path.FileMakerPathToNativePath](PathFileMakerPathToNativePath.md) to convert a FileMaker path to a native path if required. If you like to have the user choose the path, you can use [FileDialog](component_FileDialog.md) functions.  
### See also

- [Path.FileMakerPathToNativePath](PathFileMakerPathToNativePath.md)
- [Twain.CurrentImage](TwainCurrentImage.md)
- [Twain.GetFilePaths](TwainGetFilePaths.md)
- [Twain.GetFolderPath](TwainGetFolderPath.md)
- [Twain.SetCompressionQuality](TwainSetCompressionQuality.md)
- [Twain.SetFileType](TwainSetFileType.md)

### Example Databases

- [Mac and iOS/PDFKit/Pictures to PDF](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Mac%20and%20iOS/PDFKit/Pictures%20to%20PDF.shtml#4ScriptAnchor_)
- [Win Only/Scanning/Twain](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Win%20Only/Scanning/Twain.shtml#10ScriptAnchor_)

### Blog Entries

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

This function is free to use.

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

  
[Twain.SetFileType](TwainSetFileType.md) - [Twain.SetGamma](TwainSetGamma.md)

[HTML Version](TwainSetFolderPath.shtml)