> ## Documentation Index
> Fetch the complete documentation index at: https://docs.rdrive.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Computation: How to Set Up in a Form

> Computation is a module designed to assist you in creating forms with 'computed fields.' These fields calculate their values based on other fields’ inputs, simi

# **What is Computation?**

**Computation** is a module designed to assist you in creating forms with "computed fields." These fields calculate their values based on other fields’ inputs, similar to Excel formulas.

### Supported Formulas

Most Excel formulas can be applied in Computation on RDrive, including:

* `SUM`

* `VLOOKUP`

* `AVERAGE`

* `LEN`

* `IF`

***

***Important Notes for Efficient Use of Computation Functions***

* ***Avoid Referencing Entire Columns**: Do **NOT** use references like A:A or B:C (referencing entire columns) in your formulas. This practice can significantly degrade performance, especially in large datasets. Always specify a defined range that contains meaningful data (e.g., A1:A100) to ensure your computations run efficiently.*

* ***Merged Preset Spreadsheets**: Be aware that if you have a spreadsheet with a merged preset, any data added to a sheet with the same title will override the existing content.*

* ***Triggered Calculations**: Computed values in RDrive only update when the input value they depend on is edited. This means that if a source value changes, the computed field will reflect this change automatically, ensuring that outputs remain current without manual updates.*

* ***Avoid Using the Same Field for Input and Output**: Do not configure a field to act as both input and output simultaneously. This can lead to circular references and unexpected behavior in computations.*

* ***Output Fields and Conditional Editing**: Output fields function based on the conditional editing rules set up. If a field is not editable in its current status, the output will not display. Ensure conditional editing rules are correctly configured for the desired behavior.*

* ***Template's Spreadsheets Size Limit:** 100KB*

***

# **Setting Up Computation for** **a Form** - (Using a Petty Cash Report as an Example)

### **Step 1: [Design the Form Layout](https://docs.rdrive.io/setup/company/categories/categories-process-template/how-to-update-the-process-template-form)**

1. Edit or create fields and [assign field types](https://docs.rdrive.io/setup/company/categories/categories-template-setup-knowledge-base/what-can-field-properties-do) using the **Form Wizard**.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/gOU4sLLbgH4xi6TJGHk0uidGgqedHM07Dg.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=13225d380f3447c5e9ccb401192a0326" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/gOU4sLLbgH4xi6TJGHk0uidGgqedHM07Dg.png" />

2. Design the form layout in the [Form Wizard](https://docs.rdrive.io/setup/company/categories/categories-process-template/what-can-i-do-at-the-form-wizard).

   **Tips:** To make the *Output* field uneditable manually, [you may set the field type to Read Only](https://docs.rdrive.io/setup/company/categories/categories-template-setup-knowledge-base/what-can-field-properties-do).\
   *The following field types are NOT supported as output values:*

   * *Image*
   * *Signature*
   * *List (team, user, list)*
   * *Checkbox*
   * *Pass/Fail/NA*\\
     <img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/GTGQxYy6asyw-MJ4Dj8gaxOPKyKGDdIBAw.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=aee496a9f33019459fd818ae2c874c17" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/GTGQxYy6asyw-MJ4Dj8gaxOPKyKGDdIBAw.png" />

### **Step 2: Access the Computation Dialogue**

* Use **⌘/Ctrl + 6** or select **Computation** from the ⋮ (More Tools) menu to open the dialogue.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/eOqecMrzg2vAL8-9rN04do5jFLXBdAJmUQ.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=83cf8f0d94d66a4ea61bd154877b96ac" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/eOqecMrzg2vAL8-9rN04do5jFLXBdAJmUQ.png" /><img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/F6tV2bfAduuRXklf-IrcKDqWynlEC2dB1A.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=5788935e252360aff53f87efd275841f" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/F6tV2bfAduuRXklf-IrcKDqWynlEC2dB1A.png" />

### **Step 3: Edit the Spreadsheet**

1. Click **EDIT** to open the spreadsheet.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/h3Nz8_8t4XPujah2ChFDYB-__hNiXTkPKw.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=05ada5b534a8aeb246280f634e393325" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/h3Nz8_8t4XPujah2ChFDYB-__hNiXTkPKw.png" />

2. Download the Excel template via the ⋮ menu in the Computation dialogue.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/qITaqwrEfYM0hIKrvzUzuD1wcWr2ENep2w.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=50de1522cbfee99c808e1f495f077abf" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/qITaqwrEfYM0hIKrvzUzuD1wcWr2ENep2w.png" /><img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/aWItJ5-OZBsGgqJvz9t1QZafeQ5cj0m64w.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=b9c9fde3383fe62ed892ba4ceb27f8d1" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/aWItJ5-OZBsGgqJvz9t1QZafeQ5cj0m64w.png" />

3. Open the downloaded Excel file.

4. Design the input and output cells, and enter the desired formulas.  \
   *Template's Spreadsheets Size Limit: 100KB*\
    [](https://docs.google.com/spreadsheets/d/1SZNsOQgeplDtkI145yIQ3XVC9qsXWnWp/edit?usp=sharing\&ouid=104843957967887312407\&rtpof=true\&sd=true)[*(Click here to download the practice Excel file.)*](https://docs.google.com/spreadsheets/d/1SZNsOQgeplDtkI145yIQ3XVC9qsXWnWp/edit?usp=sharing\&ouid=104843957967887312407\&rtpof=true\&sd=true)<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/5xEa6f_f4PNbIY7WGiMNQaXGA9wTCPfKDg.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=6e9bb5046a140d3e55ef907e9f5ad607" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/5xEa6f_f4PNbIY7WGiMNQaXGA9wTCPfKDg.png" />

5. Save your edits in Excel and upload the file back into RDrive.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/Zyomk17cXrUbyzKx66rFr0cksQwcxdH2dQ.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=6ac5d973c446bd153aca3f65da0af984" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/Zyomk17cXrUbyzKx66rFr0cksQwcxdH2dQ.png" />

6. The Excel file has been uploaded. Please review the spreadsheet. If any functions are not applicable, an error message will appear.

   The spreadsheet will save automatically. Click the **X** icon to return to the computation dialogue.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/ueeEG5PuxASqnvxw9jMomqeQnejiNdl44g.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=2460607427a4b3accfae4a96c2008974" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/ueeEG5PuxASqnvxw9jMomqeQnejiNdl44g.png" />

⚠️ **Warning:** Avoid creating or edit the spreadsheet directly on the web. Always use the downloaded Excel file to ensure formula compatibility.

### **Step 4: Map Fields to Spreadsheet Cells**

1. Assign input and output values:

   * **Input Fields:** Any field type.

   * **Output Fields:** Any field type except image, signature, team list, user list, or dropdown list.

2. Click **Select** in the Computation dialogue to map form fields to spreadsheet cells.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/X1J8EVEZRzp8JeR6HUpSP5FOjVlkiFDqcA.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=3a6a41248d5778302336df162b68084a" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/X1J8EVEZRzp8JeR6HUpSP5FOjVlkiFDqcA.png" />

3. Highlight fields in blue by clicking on them.

4. Press **✔** (bottom-right corner) to confirm, or click outside the dialogue to cancel.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/pMfgujq6XIUUOSGM1cfR0CAreJLmSRWI-w.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=40da8f6528953a061d004e1252d6f580" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/pMfgujq6XIUUOSGM1cfR0CAreJLmSRWI-w.png" />

### **Step 5: Finalize the Setup**

1. Complete input and output mapping.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/MRnXZKa7Qwo48vTIy_cZmegfgwwO6MqVCQ.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=295d89c0c24bb94e251d12205bfd9614" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/MRnXZKa7Qwo48vTIy_cZmegfgwwO6MqVCQ.png" /><img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/PYzDWUrJ912qwVHIdkHgoI34tcnOZGdTKA.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=f1f8ffaa07d5b296b5d7f117a38e4022" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/PYzDWUrJ912qwVHIdkHgoI34tcnOZGdTKA.png" /><img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/uAJ5jAc88WWqejRBcxkFHVNITuZmSC6k6Q.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=6c6ef68df6818cdbcd7166eafba96f0b" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/uAJ5jAc88WWqejRBcxkFHVNITuZmSC6k6Q.png" />

2. Input Completed.

   Please repeat the above steps for the Output to assign values. Click OK to finish.

   <img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/BSDDdqlLjOxCmyHkwxdb3i1EhBMC6rmRyA.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=e4270ef73d83ee2cfeb26bf0e7d8ff2e" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/BSDDdqlLjOxCmyHkwxdb3i1EhBMC6rmRyA.png" />

   <img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/DiezaORXbDkcipcJXUCv8aDG9HFuOl7JKQ.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=b84833212dbedbbdbbc85e1445345608" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/DiezaORXbDkcipcJXUCv8aDG9HFuOl7JKQ.png" />

   <img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/p-LOduWdzTq2bQ9_8mnLY8qmMf6hJPYZUg.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=8fe6dae15a581c1de7064cf1f8033686" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/p-LOduWdzTq2bQ9_8mnLY8qmMf6hJPYZUg.png" />

3. Save the configuration.<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/AYiwkFJnx-6yCtN89YHYRh1uVYJaF3e8xQ.png?fit=max&auto=format&n=sdA2WDD3FaUG1SbF&q=85&s=8986b94a385b5d2b0a310b3f7be0ea1d" alt="Computation: How to Set Up in a Form" width="1024" height="768" data-path="images/kb/103000035014/AYiwkFJnx-6yCtN89YHYRh1uVYJaF3e8xQ.png" />

4. [Don't forget to click Publish to apply the updates to the form.](https://docs.rdrive.io/setup/company/categories/categories-process-template/create-a-process-template-with-form#h_acd539a98d)

The GIF below demonstrates the mapping steps for your reference.

<img src="https://mintlify.s3.us-west-1.amazonaws.com/rdrive/images/kb/103000035014/AzXN8944WDSWdal-_L7l9uwp-FvhKjpxJw.gif" alt="Computation: How to Set Up in a Form" />

***

## **Example of Computed Field Behavior**

**Scenario:**

* Field: `Total`

* Formula: `SUM` of values entered in the `Amount` field.

The value in the `Total` field automatically updates whenever the `Amount` values change.

<img src="https://mintcdn.com/rdrive/sdA2WDD3FaUG1SbF/images/kb/103000035014/Mcq2E_veUgCwdmhx4K1_Bhyq2HBL9wUHuA.gif?s=b89736980c148ea5a1503c9a512f9dfe" alt="Computation: How to Set Up in a Form" width="960" height="720" data-path="images/kb/103000035014/Mcq2E_veUgCwdmhx4K1_Bhyq2HBL9wUHuA.gif" />

***

## **Additional Resources**

* [Set up computation for the issue template](https://docs.rdrive.io/setup/company/categories/categories-issue-record-template/computation-issue)

* [Edit spreadsheets at the project level](https://docs.rdrive.io/setup/company/presets/preset-spreadsheet-add-and-merge-with-the-template-company-level)

If you have further questions, contact support for assistance.
