Forms Designer - Formula Editor

Modified on 2015/02/13 19:04 by Adam — Categorized as: Uncategorized

The Formula Editor is an advanced tool for writing Formulas in Surety Pro's Forms Designer.

It can be used by the form modifier to assist is writing formulas.  It will automatically close brackets and quotations when typing as well as color code the different parts of the formula for clear definition.

The formula editor can also provide you with a list of options when using the formula to pull data from other forms. (see below)

CURRENTLY THE FORMULA EDITOR IS IN BETA FORM - All features have not been fully tested - Use the editor only within an Internet Explorer Browser's latest version. 

Start by selecting the Control item that you want to add or modify a formula for.

Image

Click on the pencil icon next to the text area to open the Formula Editor.

Image

In order to initiate a formula an equals sign(=) must be placed at the beginning of the entry.

=

Writing a Formula using the Formula Editor

When composing your formula the editor will color the parts depending on what their function is. Any references to controls are displayed as a dark blue font. A literal value surrounded in quotations is colored as red. Purple is assigned to parts of the formula that indicate what to do.

Image

Using a formula to pull values from other forms.

Using the !, a formula can be constructed to pull values from previously saved forms on that specific field. 

In this example we want to pull the "CropName" data from the previous year and place it into the "PreviousCropName" field. 



Click on the field we want to pull data into (In this case, PreviousCropYear) and click the pencil icon to open the Formula Editor.



Image

Start by indicating a formula with the equals (=) sign and then add an exclamation point to start the formula editor.

=! Select the Crop Year that you would like to pull data from


For this example we want to pick Previous Crop Year



Caveat: use the arrow keys on the keyboard to highlight your selection and then press enter to accept it. For long lists, start typing in the value you want to narrow the list. 



Image

place a period "." and the next drop-down of information will appear. 

Select the type of Form to pull data from.


This custom form example is named Chucks~Chemical



Image

place a period "."

Select a location


Image

place a period "."

Choose what field to pull values from. 




In our example we want to pull the previous year's CropName.



Image

place a period "."

Select what data you want to populate and how. 


Image

Click Save

Image

Publish and test your results by generating a new form using a boundary that contains a saved form that is referenced. 

In this case, I will generate this form from this location on the save border that I have saved a "Chuck's Fertilizer" form on for the previous Crop Year.

If there was a Crop Name saved in the previous year's form, it will pull that Crop Name and place it into the current year's Previous Crop Name blank.

Image

See also: