---
schema_version: "1"
id: be1f9813103c10178877c382d8c622f8741590c631b40bfc2378ab5eea902518
title: AMPscript Function Parameters
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/marketing-cloud/ampscript/guide/language-basics/mc-ampscript-guide-language-basics-parameters.md
canonical_url: https://developer.salesforce.com/docs/marketing/marketing-cloud-ampscript/guide/mc-ampscript-guide-language-basics-parameters.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 3c0646a2379f85650bc669f17b0be048ea434838b84163a48fa50c0479a75be0
products:
  - AMPscript for Marketing Cloud
  - Marketing Cloud
---
# AMPscript Function Parameters

AMPscript functions use parameters that you must specify in a specific order. The reference section of this guide lists the parameters for each function in the order in which they must be passed. For example, the entry for the `FormatCurrency()` function shows that it has this syntax:

`FormatCurrency(number, cultureCode, decimalPlaces, currencySymbol)`

In this function, the number that you want to convert to a currency value (`number`), must always be listed first, followed by the locale code to use when formatting the string (`cultureCode`), and so on.

## Optional Parameters

Some functions have one or more optional parameters. In the `FormatCurrency()` function, the last two parameters (`decimalPlaces` and `currencySymbol`) are optional. If you want to pass a value for the `currencySymbol`, you must also pass a value for the parameter that precedes it in order (`decimalPlaces`). In this situation, you can pass `null` or an empty string ("") to skip over parameters that you don’t want to specify.

## Function Input Types

AMPscript functions accept any of these input types:

- Constant values, such as `Lowercase("Mary Smith")`
- Attribute values, such as `Lowercase(Name)`
- Variable values, such as `Lowercase(@Name)`

To prevent infinite loops, you can’t call AMPscript functions recursively. Recursive functions result in a "104 - RecursiveScriptError" exception. Email, SMS, and push messages that result in this type of exception are considered "Errored/NotSent," and count against the subscriber error limit threshold.
