नोट
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप साइन इन करने या निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
Syntax
Expression.Evaluate(document as text, optional environment as nullable record) as any
About
Returns the result of evaluating an M expression document, with the available identifiers that can be referenced defined by environment.
Example 1
Evaluate a simple sum.
Usage
Expression.Evaluate("1 + 1")
Output
2
Example 2
Evaluate a more complex sum.
Usage
Expression.Evaluate("List.Sum({1, 2, 3})", [List.Sum = List.Sum])
Output
6
Example 3
Evaluate the concatenation of a text value with an identifier.
Usage
Expression.Evaluate(Expression.Constant("""abc") & " & " & Expression.Identifier("x"), [x = "def"""])
Output
"""abcdef"""