Survey123 Multi-Stage Form and Power Automate Flows

02-26-2021 06:13 AM
by Anonymous User
Not applicable

Hello, I created a multi-stage inspection form and feature service through Survey123 Connect 3.11 and consistent with the tutorial found under the Advanced XLSForm Techniques video. The inspection form has been broken up into 3 different stages--Citizen Submission (Stage 1), Initial Inspection (Stage 2), and Follow Up Inspection (Stage 3)--and collects against a single feature service. The ultimate goal is to embed stage 1 onto a website for public data collection and to automate the flows upon submission of a survey using Microsoft Power Automate. Working through the development of the automation, I have come across two problems thus far. 

  1. I have embedded stage one onto our website with an iframe code. However, when a survey is submitted through the website, the Case ID, which is calculated in the XLSForm by adding two other fields together, is returned as a "NaN" whereas when a survey is submitted through the desktop/phone app, the Case ID is returned as an actual string value. I believe there may be an issue with the connection between our website and the survey that is causing Survey123 to not recognize the Case ID string when it is submitted. Has anyone come across this or could help configure another way to embed the survey onto the website without including a direct hyperlink? 
  2. When Stage 1 has been submitted, it arrives into Stage 2's inbox queried WHERE report_status='new'. The goal here is to collect initial inspection information against the same Case ID and to allow the end user to see the Stage 1 data submitted as read only in the Stage 2 survey. However, when editing the initial inspection form (Stage 2) upon the submission of Stage 1, I am finding the survey is not allowing me to collect images and signatures within the form. When I collect on a brand new, blank Stage 2 form there is no issue collecting the images or signatures. Is there a setting that needs to be made that allows editing of images within the survey or survey123 connect, or just a way around this? 

I have included Stage 1 and Stage 2 XLSforms for your reference. 

0 Kudos
0 Replies