FM.ScriptNameForScriptID
------------------------

Queries script name for a script ID.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [FM](component_FM.md) | [5.1](newinversion51.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "FM.ScriptNameForScriptID"; ScriptID { ; FileName } ) 

**MBS**( **"FM.ScriptNameForScriptID";** /\* Queries script name for a script ID. \*/  
**$ScriptID**; /\* The ID of the script.e.g. "123" \*/   
**$FileName**) /\* Optional; The name of the file to look inside.  
If empty, we default to current file.  
  
Using a table in another database file may require you adding the other file as an external data source and adding the external table to your relationship graph to grant access. \*/ 

### Parameters

| Parameter | Description | Example | Flags |
|---|---|---|---|
| ScriptID | The ID of the script. | "123" |  |
| FileName | The name of the file to look inside.   If empty, we default to current file.      Using a table in another database file may require you adding the other file as an external data source and adding the external table to your relationship graph to grant access. |  | Optional      Added in version **7.5**. |

### Result

Returns name or error.

### Description

Queries script name for a script ID.  
### Examples

Query script name:

 MBS ( "FM.ScriptNameForScriptID"; 146 )  
### Release notes

- **Version 7.5**
    - Added FileName parameter to [FM.ScriptNameForScriptID](http://www.mbsplugins.eu/FMScriptNameForScriptID.shtml), [FM.ScriptIDForScriptName](http://www.mbsplugins.eu/FMScriptIDForScriptName.shtml) and [FM.ScriptNames](http://www.mbsplugins.eu/FMScriptNames.shtml).

### Blog Entries

- [News about the MBS FileMaker Plugin 10.2](https://www.mbsplugins.de/archive/2020-05-19/News_about_the_MBS_FileMaker_P/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 7.5pr2](https://www.mbsplugins.de/archive/2017-10-16/MBS_FileMaker_Plugin_version_7/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 5.1pr2](https://www.mbsplugins.de/archive/2015-03-23/MBS_FileMaker_Plugin_version_5/monkeybreadsoftware_blog_filemaker)

This function is free to use.

Created 23th March 2015 , last changed 20th March 2023

  
[FM.ScriptIDForScriptName](FMScriptIDForScriptName.md) - [FM.ScriptNames](FMScriptNames.md)

[HTML Version](FMScriptNameForScriptID.shtml)