Functions for Merge Fields

List of functions available for merge fields in Office File Creator.

 

Date/Time

Today() and Now() functions are available in Office File Creator Ver. 2 or later.

Today() Function

Output today's date.

{!Today()}

 

Now() Function

Output the current date and time.

{!Now()}

 

 

Functions for child record

Blank() and aggregate functions are available in Office File Creator Ver. 2 or later.

Number() Function

Output sequential numbers in the child record output line.

{!Number()}

{!Childrelationship Name.Number()}

e.g. {!OpportunityLineItems.Number()}

 

Blank() Function

Output blanks. Used to adjust block rows in child records.

{!Childrelationship.blank()}

e.g. {!OpportunityLineItems.blank()}

 

Aggregate Functions

Output the aggregate value of child records. Aggregate functions can only be used for child objects for which grouping has been set in the OFC_Child Object Option record. Group output is available only in Excel.

{!Childrelationship Name.Aggregate Function(Field API Name)}

e.g. {!OpportunityLineItems.Sum(TotalPrice)}

 

Aggregate Function Description Example of Merge Field
Sum() Returns the total sum of a numeric field. {!OpportunityLineItems.Sum(TotalPrice)}
Count() Returns the number of group rows. {!OpportunityLineItems.Count(Id)}
Avg() Returns the minimum value of a field. {!OpportunityLineItems.Avg(TotalPrice)}
Min() Returns the minimum value of a field. {!OpportunityLineItems.Min(TotalPrice)}
Max() Returns the maximum value of a field. {!OpportunityLineItems.Max(TotalPrice)}

 

Memo

If the group field is a formula field, the aggregate function cannot be used.

 

 

Functions for PDF

Pagenumber() Function

Output page numbers.

{!pagenumber()}

 

Pagecount() Function

Output the total number of pages.

{!pagecount ()}