Survey123: How to maintain trailing zeros in rounded Lat/Long numbers

186
2
Jump to solution
07-27-2020 09:55 AM
Katherine_Clark
MVP Regular Contributor

Hello,

I created a survey in Survey123 Connect that automatically records the coordinates of the point and displays them to the user in a Note field.

I have that note field set to round to 6 decimal places, but in cases where there are zeros at the end of the coordinate, it does not display the zero. Here is an example:

For consistency in the final reports, it is important this this field always have 6 decimal places, even when the last number is a zero. Is there a way to accomplish this?

Reply
0 Kudos
1 Solution

Accepted Solutions
JamesTedrick
Esri Esteemed Contributor

Hi Katherine,

There isn't a direct number padding/formatting function in the XLSForm; that being said, we should be able to do this in the future with custom JS function (currently in beta) using the .toFixed() method - JavaScript Number Methods 

View solution in original post

2 Replies
JamesTedrick
Esri Esteemed Contributor

Hi Katherine,

There isn't a direct number padding/formatting function in the XLSForm; that being said, we should be able to do this in the future with custom JS function (currently in beta) using the .toFixed() method - JavaScript Number Methods 

View solution in original post

Katherine_Clark
MVP Regular Contributor

Thanks James. I learned about custom JS functions at the UC and it seems I'll be able to use them to fix several of the roadblocks that I've been facing with Survey123. Very excited about this capability! (now, time to learn JS...)

Reply
0 Kudos