I have two fields in each record that are “feet” & “meters” – the elevation of a location.
Sometimes I know the feet and sometimes I know the meters to enter, but rarely both without converting with another app. Is there a way to enter either entry and have the other automatically calculated? I know I can do one-way calculation, but how would I do one or the other?
Hi Glen,
You would need to use a Script field for this. In your Script field you’ll need to get the value of each field. Then do your conversion, then set the value in the other field. Just check to make sure you set the value on the field if it’s empty.
https://www.tapforms.com/help-mac/5.3/en/topic/javascript-api
Have you done any scripting in Tap Forms before?
Thanks,
Brendan
I’ve tried to learn, but just can’t spend enough time to remember enough. Went through quite a bit of a javascript course, but then time got short and I started forgetting stuff.
If this was a little bit more straight forward, I would try ChatGPT. I’ve asked it to program some things and I’m amazed at the results.
The other concern is since I already have 70 records all filled in I don’t want to lose that data, so I have to build in a double if clause that if both fields are filled not to do anything (I guess that would be my first If clause in which all else would occur.
Some Script help here would be greatly appreciated.
Thanks.
Hi,
You could have a record which records the value. A second record with a dropdown which loads if the measurement is metric or imperial. A 3rd record which is a calculation field which performs the conversion based on what the second record is set at based on an ‘If’ calculation.