Show / Hide Table of Contents

    FORMATSTRING

    Specification Value
    Description Returns a specified object formatted by specified rules.
    Parameter 1 Name Param1
    Parameter 1 Type object (any type)
    Parameter 2 Name Format
    Parameter 2 Type constant
    Parameter 3 Name -
    Parameter 3 Type -
    Return value Param1 as a string formatted by the rule in Format.
    Note

    The format argument must contain a valid .NET format string, either as a standard string ("C" or "D") or as a pattern of custom characters for dates and numeric values ("MMMM DD, yyyy (dddd)").
    For more information about supported format specifiers, see Format specifiers.

    Example:

    Let's see some formats and format specifiers:

    10: FORMATSTRING CONST:DocumentDate CONST:yyyy MM dddd
    

    OUTPUT:
    If 'DocumentDate = 2020-03-15', the output will be '2020 03 Sunday'.
    (the language of the day of the week depends on the local regional settings)

    10: FORMATSTRING ATTRIB:QuantityValue CONST:n6
    

    OUTPUT:
    If 'QuantityValue = 150.00', the output will be '150,000000'.
    (the decimal symbol separator depends on the local regional settings)

    10: FORMATSTRING ATTRIB:LineAmountValue CONST:C
    

    OUTPUT:
    If 'LineAmountValue = 150.00', the output will be '150.00 $'.
    (the decimal symbol separator and the currency symbol depends on the local regional settings)

    Note

    The repository of the attribute is Crm.Sales.SalesOrderLines

    • Improve this Doc
    Back to top Generated by DocFX