Jump to content
Sign in to follow this  

Increment value in one field based on status in another field

Recommended Posts

Hi, you may use the following script in the footer of the datapage:

function calculate()

var check = document.getElementById("InsertRecordField_name").value;

if(check =="Approved"){

var v_increment = parseFloat(document.getElementsByName("cbParamVirtual1")[0].value);

   document.getElementById("InsertRecordField2").value = v_increment+1;



You need to use a virtual field to sort values in descending order and get the last submitted value, then increment value and write in a field

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this