EnvironmentVariables.Value
--------------------------

Queries value of an environment variable.

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

MBS( "EnvironmentVariables.Value"; Name ) 

**MBS**( **"EnvironmentVariables.Value";** /\* Queries value of an environment variable. \*/  
**$Name**) /\* The name of the environment variable.e.g. "test" \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| Name | The name of the environment variable. | "test" |

### Result

Returns text or error.

### Description

Queries value of an environment variable.  
### Examples

Query user name on Mac:

 MBS ( "EnvironmentVariables.Value"; "USER" )  
Query user name on Windows:

 MBS ( "EnvironmentVariables.Value"; "USERNAME" )  
Query app data path on Windows:

 MBS ( "EnvironmentVariables.Value"; "APPDATA" )  
Query language on FileMaker Cloud:

 MBS ( "EnvironmentVariables.Value"; "LANG" )  
### See also

- [EnvironmentVariables.ClearValue](EnvironmentVariablesClearValue.md)
- [EnvironmentVariables.Count](EnvironmentVariablesCount.md)
- [EnvironmentVariables.JSON](EnvironmentVariablesJSON.md)
- [EnvironmentVariables.Name](EnvironmentVariablesName.md)
- [EnvironmentVariables.Names](EnvironmentVariablesNames.md)
- [EnvironmentVariables.SetValue](EnvironmentVariablesSetValue.md)

### Example Databases

- [Utility functions/Environment Variables](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Utility%20functions/Environment%20Variables.shtml#1ScriptAnchor_)

### Blog Entries

- [FileMaker Cloud Tipps &amp; Tricks](https://www.mbsplugins.de/archive/2017-12-10/FileMaker_Cloud_Tipps__Tricks/monkeybreadsoftware_blog_filemaker)

This function is free to use.

Created 8th April 2015 , last changed 10th December 2017

  
[EnvironmentVariables.SetValue](EnvironmentVariablesSetValue.md) - [ErrorLog](ErrorLog.md)

[HTML Version](EnvironmentVariablesValue.shtml)