You are viewing limited content. For full access, please sign in.

Question

Question

Subtotal not showing up in LF from form

asked on February 5, 2015

I have a form on version 9.2 that does a lookup to get price and quantity and comes up with a subtotal on each line.  Then it uses the subtotals to do other calculations at the bottom.  All the calculations seem to be correct but when I save to the repository all the line item subtotals disappear.  All the rest of the calculations are still visible.

I have added the java script calculations that I am using plus pics of the line items, the totals at the bottom on the form and then what is saved in the repository. 

Line Subtotals.GIF
Form Totals.GIF
Saved Form.GIF
Saved Form.GIF (11.53 KB)
0 0

Answer

SELECTED ANSWER
replied on February 6, 2015

Hello Dave,

This is caused by the way the Forms Server and browser communicate. Basically, when the Forms Server stores the submitted form, it will only store values of Read Only fields that were filled by the Forms Server, for example by lookups. By using JavaScript, you are asking the browser to fill this Read Only field, and so the Forms Server will reject the value for security reasons.

If you unset Read Only on the fields under the Total Cost column, then the values will be saved, and you can set the field inputs to be Read Only using JavaScript rather than the Form Editor, which will allow Forms to store the values filled by the JavaScript.

 

$(document).ready(function(){

  
  $("#Field6")[0].readOnly = true;
});

Thanks,

0 0
replied on February 6, 2015

Thank you Nathan!  That worked great!
 

0 0
replied on February 6, 2015

Good looking form Dave!

0 0
replied on February 9, 2015

Thanks Blake!  Do you want a copy? 

 

0 0

Replies

replied on April 28, 2016

This was extremely helpful, thanks!

 

I used 

$('#q310 input').attr('readonly', true);
0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.