Pulldata not working in webform

1103
3
03-15-2019 04:38 PM
N_Funi
by
New Contributor II

I created a survey in Survey123Connect and am having trouble getting the webform to load, I get an error message-  “Error: Initialing Form...”. When I close the error message I can proceed with the webform but none of the pulldata calculations seem to be working (they work as expected in Survey123Connect).

My goal with this survey was to get a geopoint for new locations signing up for the heat relief network, for previous participants, I was using the pulldata function to have them verify their last year’s information is still correct.

I’m attaching the form and lookup table for the pulldata.

Here is a link to my survey

https://arcg.is/1qPzDO 

corresponding tables attached

0 Kudos
3 Replies
JamesTedrick
Esri Esteemed Contributor

Hi Nicole,

There are a couple of issues with the form & CSV file:

- the combination of readonly=yes and appearance=multiline is generating the immediate error. I would suggest simply turning those questions into note questions 

- Some of the column headings in the CSV are too complex - I would reduce them to a single world.

0 Kudos
N_Funi
by
New Contributor II

Thank you James, I was able to get the pulldata function to work with your suggestions.

Is it possible to generate new lines on a webform within a concatenation when using pulldata? Using "\n" works as expected in Survey123 Connect but on the webform the string comes back on one line and displays \n in the concatenated text. Using single quotes or <br> gives me an error when I try to update my survey.

Here’s the calculation I’m using:

concat(pulldata('HRN_LUT', 'Hydration_Type', 'LUT_Facility', ${Facility}),"\n",pulldata('HRN_LUT', 'Donation_Type', 'LUT_Facility', ${Facility}))

0 Kudos
JamesTedrick
Esri Esteemed Contributor

Hi Nicole,

As the web form uses html, <br /> should be the appropriate html tag for a line break. It's working for me in a test survey, though I am seeing it insert an extra <br />

0 Kudos