Survey123 Web form URL parameters

398
2
10-15-2020 07:42 AM
SkylerDewey
New Contributor III

Using Survey123 Web form URL parameters,  is it possible to pass a date field as one of the field parameters?

0 Kudos
2 Replies
ZacharySutherby
Esri Regular Contributor

Hello Skyler Dewey‌, 

You should be able to pass a date into a date field using the Web form URL parameters. The syntax would look something like: 

https://survey123.arcgis.com/share/<Form item ID>?field:_date=10/14/2020 

Or if the question is a date/time question it would look like: 

https://survey123.arcgis.com/share/<Form Item ID>?field:datetime=10/14/2020%2012:23

This would return October 14th, 2020 12:23 PM.

Thank you, 

Zach

Thank you,
Zach
0 Kudos
SkylerDewey
New Contributor III

Thanks for the quick reply.  The date shows up in the url string but it is not populating the field in the form (example of the date showing up just as expected in the browser url &field:SymptomOnsetDate=9/9/2020)? 
Does the field need to be formatted a specific way for it to also display there as well?  

field:CASELastName={LastName}&field:SymptomOnsetDate={IllnessOnsetDate} 

Quite a few fields are passed successfully above is just the first two of the long url.  The field SymptomOnsetDate "type" in Survey123 is just date, it doesn't have any other special formatting associated with it?

typenamelabelhintconstraintconstraint_messagerequiredrequired_messageappearancedefaultreadonlyrelevantcalculationchoice_filterrepeat_countlabel::language1hint::language1media::audiomedia::imagebody::accuracyThresholdbind::esri:fieldTypebind::esri:fieldLengthbind::esri:fieldAliasbody::esri:inputMaskbody::esri:stylebind::esri:parametersbind::saveIncompletebind::typebind::esri:warningbind::esri:warning_messageparameters
dateSymptomOnsetDateEnter Illness Onset DateThis date could be the date of first positive specimen OR Symptom onset dateyesesriFieldTypeDate

Thanks so much for any help figuring out where I'm going wrong here!

0 Kudos