Select to view content in your preferred language

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

2268
2
Jump to solution
07-27-2020 09:55 AM
Katie_Clark
MVP Alum

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?

Best,
Katie

If this answer helped you, please consider giving a kudos and/or marking as the accepted solution. Thanks!
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 

Katie_Clark
MVP Alum

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...)

Best,
Katie

If this answer helped you, please consider giving a kudos and/or marking as the accepted solution. Thanks!
0 Kudos