Menu

Field Codes to Access Data in Tables

Updated: 2025-03-18

Throughout TaxCycle, you will find expanding tables for data entry and review. They start out as a single row and expand to add new rows at you enter data. You can use the field codes from cells in these tables to display data in templates.

Row Numbering

In the example, [0], [1] and [2] correspond to the rows of the medical expenses table. Counting starts at zero.

The empty row at the bottom of the table, indicated by a [-1], will change when you start typing in a field. Avoid using codes containing [-1] in templates or conditions.

  • First row: {{CurrentClient.MedicalExpenses.ExpensesDetails[0].Amount}}
  • Second row: {{CurrentClient.MedicalExpenses.ExpensesDetails[1].Amount}}
  • Third row: {{CurrentClient.MedicalExpenses.ExpensesDetails[2].Amount}}
  • Empty row: {{CurrentClient.MedicalExpenses.ExpensesDetails[-1].Amount}}

Screen Capture: Numbering of Field Codes in Rows

It’s crucial to understand that the sequential numbering corresponds to the presentation order of the table’s rows. If you rearrange the rows, the field code will change. 

How to Avoid Referencing a Specific Row by Its Number

When accessing tabular data, it is wise to avoid referencing a specific row by its number. Instead, break down the field code and use functions to filter and display the results. 

Example 1: List All Values From a Table Column

To list all the medical expense amounts entered in a template:

  1. Copy the field code from the first cell in the Amount column on the Medical expense worksheet.
  2. Paste the field code into the template.
  3. This will display the amount from that cell in the preview.
  4. To generate a list of all the amounts in that column, break apart the field code:
    1. Create an opening and closing condition for the CurrentClient context.
    2. Create an opening and closing condition for the MedicalExpenses.ExpensesDetails portion of the field code, removing the row number.
    3. Leave the Amount on its own to pull the data.
  5. The preview will show all the amounts in the column. If you add an amount in another row, it will appear at the bottom of the list.

Screen Capture: Medical expense list in a template