Value function in Power Apps
Converts a string of text to a number.
The Value function converts a string of text that contains number characters to a number value. Use this function when you need to perform calculations on numbers that were entered as text by a user.
Different languages interpret , and . differently. By default, the text is interpreted in the language of the current user. You can specify the language to use with a language tag, using the same language tags that are returned by the Language function.
Notes on the format of the string:
- The string may be prefixed with the currency symbol for the current language. The currency symbol is ignored. Currency symbols for other languages aren't ignored.
- The string may be include a percent sign (%) at the end, indicating that it's a percentage. The number will be divided by 100 before being returned. Percentages and currency symbols can't be mixed.
- The string may be in scientific notation, with 12 x 103 expressed as "12e3".
If the number isn't in a proper format, Value will return an error.
To convert date and time values, use the DateValue, TimeValue, or DateTimeValue functions.
Value( String [, LanguageTag ] )
- String - Required. String to convert to a numeric value.
- LanguageTag - Optional. The language tag in which to parse the string. If not specified, the language of the current user is used.
Value( Untyped )
- Untyped - Required. Untyped object that represents a number. Acceptable values are dependent on the untyped provider. For JSON, the untyped object is expected to be a JSON number, boolean, or text that can be converted to a number. Keep in mind that locale-related formats are important considerations when communicating with external systems.
The user running these formulas is located in the United States and has selected English as their language. The Language function is returning "en-US".
|Value( "123.456" )||The default language of "en-US" will be used, which uses a period as the decimal separator.||123.456|
|Value( "123.456", "es-ES" )||"es-ES" is the language tag for Spanish in Spain. In Spain, a period is a thousands separator.||123456|
|Value( "123,456" )||The default language of "en-US" will be used, which uses a comma as a thousands separator.||123456|
|Value( "123,456", "es-ES" )||"es-ES" is the language tag for Spanish in Spain. In Spain, a comma is the decimal separator.||123.456|
|Value( "12.34%" )||The percentage sign at the end of the string indicates that this is a percentage.||0.1234|
|Value( "$ 12.34" )||The currency symbol for the current language is ignored.||12.34|
|Value( "24e3" )||Scientific notation for 24 x 103.||24000|
Submit and view feedback for