Formulas and cell references |
Top Previous Next |
FormCalc SST formulas are similar to those in other spreadsheet programs. Formula RequirementsThe main requirement, is that all formulas begin with an equal sign ('='):
Beyond this requirement of course, the formula must also be "legal"—it must be constructed properly and cannot reference out-of-bounds cells or cell ranges, etc.
Where You May Enter FormulasThis screenshot below shows the areas where you may enter formulas in FormCalc SST. Most of your formulas will be entered in either these two areas: •Formulas row: formulas entered here will be applied to every row of data on your QuickBooks form except rows processed by Item-triggered formulas. •Item-triggered formulas rows: formulas entered on these rows get applied only to QuickBooks form rows which have a matching Item name. (This lets you control where special calculations like totals or subtotals get done, by your placement of certain Item names on the form.) References to Other Cells and Cell RangesCell references in formulasTo refer to another cell in a formula, enter the cell's coordinates. For instance, the following formula multiplies 34.5 times the value in cell H14.
To refer to a range of cells, specify the coordinates of the upper left and lower right cells of the range, separated by a colon (':'). This formula sums the range of cells consisting of B7, B8, and B9:
Cell referencing limitationsTo prevent errors, FormCalc SST only allows formulas to refer to specific cell ranges on the Snapshot page. Each formula is checked as you enter it, and if the formula refers to an out-of-bounds cell one of two things will happen: 1.The formula will be highlighted in the error color (red background), or 2.A message will be displayed telling you FormCalc SST has adjusted (corrected) the formula's cell references. Allowed cell references:
Referring to "a whole column"—the entire range of Formulas (Detail) cells
|
=SUM(H24:H26) |
As the red box indicates in the screenshot below, this formula refers to a cell range which includes the first and last sample row in column H:
During form processing, FormCalc SST will convert this sample rows reference into a reference to the form's entire column of Quantity data.
Actually, there's an even easier way. Instead of the formula shown above, you could enter any of the following combinations (and many others):
=SUM(H1:H1) |
=SUM(H5:H9) |
=SUM(H3:H12) |
In other words, just have your formula refer to the desired column (H in this case) and any range of rows above the Detail area of the snapshot. FormCalc SST will immediately and automatically convert what you enter to a reference to the appropriate range of sample rows. So the result of any of the three entries above will be:
=SUM(H24:H26) |
Entering "whole column" cell ranges in the form "=SUM(H1:H1)" is easiest. That way, you don't have to be concerned with knowing the exact beginning/ending coordinates of the sample rows area. |
Understanding how references to a "whole Detail column" really work. As mentioned, FormCalc SST changes these references at runtime (when processing a QuickBooks form) to refer to the actual set of Detail rows present at the time, but there is one more important point to understand: •The formula references are changed to refer to all Detail rows up to and including the prior row. In other words, "all Detail rows" does not include the QuickBooks form row which is currently being processed. |