Select to view content in your preferred language

Survey123 Tricks of the Trade (Live): Create Report Templates

5787
5
04-19-2023 12:10 PM
IsmaelChivite
Esri Notable Contributor

 

On April 19, 2023 we recorded a Tricks of the Trade session covering Survey123 feature reports. Thanks to all attendees!   In this post you will find the recording, resources and Q&A.

IsmaelChivite_0-1681930900207.png

Highlights

 

Survey123 includes a report service. With it, you can create beautiful PDF reports including maps, photos, tables and more. Build your own reports for compliance, to document the work you do, to share information with stakeholders in a format they are familiar with or simply to create high quality printable documents.

This 60' session will help you get started creating your own Survey123 report templates. It includes some basic conceptual slides, plus live demos and practical tips.

Next week we will host a session covering Report automation. Learn more about it and register here.

Recording

 

Watch here

Slides

 

Find the slides at the bottom of this post . They are attached in PDF format.

 

Q&A

 

How do you return multiple photos attached to a single feature in the report?

It’s possible to display an image question that has a multiline appearance applied to it by using the following syntax:

${#image1} ${$file} ${/}

The syntax above will display the images horizontally on the page, and adding carriage returns instead of spaces will display the images vertically:

${#image1}
${$file}
${/}

Also see the Images and other attachments section of the Survey123 Report Templates documentation.

Is there a way to connect reports to Excel so I can include a scatterplot or other chart based on site monitoring data being collected in my survey? Or is there another chart plotting tool that you would recommend?

Currently it is not possible to export reports to Microsoft Excel. There is an open ArcGIS Survey123 Idea for this enhancement, please upvote this idea so the Survey123 team can track interest in this feature.

As a potential workaround, you can insert dynamically generated images into your reports.  For example, this expression concatenates a URL to a QR code-generating service, creating a QR code image for the question's response.

${$image | src:"https://barcode.tec-it.com/barcode.ashx?code=QRCode&data="+survey123question}

It may be a long shot, but this may help you bring your plotting chart images into your reports, if you somehow can make them available via a URL

${$image | src:"https://mywebserver.com/plots/"+stationID+"jpg"}

Can the report automatically be saved to a local network drive so staff can see it once generated?

When a report is exported from the Survey123 website, the report will be saved in the user’s ArcGIS account in the location specified during export and also downloaded to the default download location. It is not possible to edit the default download location. It is also possible to use third party automation software to upload report exports to specified locations. See ArcGIS Survey123: Create Feature Reports with Integromat for an example of how to do this with Make.com (formerly Integromat). 

Is there a way to reference data from another layer (such as parcel data) that would not be collected in the survey itself?

It is not possible to do this with a report template. It would, however, be possible to use pulldata("@layer") in the survey to populate a field based on the non-survey layer. This question could then be referenced in the report template.

Can users rename photos while completing a survey?

 Yes, by default you can have users change the filename. Additionally, you can also have photo filenames automatically populated. Check this blog for details: 

Could we filter or limit the repeats? 

Yes. You will want to use the where method for that. Below is an example:

IsmaelChivite_0-1681932854914.png

Can I limit the repeat records that are shown to the last 30 days?

Yes, you will want to use the where method. Here is an example

${#inspections | where: " inspection_date BETWEEN CURRENT_TIMESTAMP - 30 AND CURRENT_TIMESTAMP" | orderByFields: "inspection_date DESC"} ... ${/}

Is there an update on implementing photos and maps within the "repeat" of a summary report

No. In a summary section, printing a map or image, including retrieving properties from an attachment file except for attachment name and size, is only supported outside of repeats. Otherwise, an error message will appear.

For dynamic visibility, how do you account for the large amount of empty space where those questions would be if they were visible?

When using a conditional section, keep in mind that any line breaks, spaces, or other characters outside of the section start and end tags will be displayed in the exported report. The section start tag can be placed immediately after the previous section to prevent unwanted line breaks from displaying in the exported report.

IsmaelChivite_0-1681933385290.png

Do we have control over the pin symbol of the specific hydrant point in the map in your example?

By default, a map question will display using a default map symbol, regardless of symbology set in the feature layer. You can use the drawingInfo method to extract and use the drawing information stored in a specific feature layer, including the symbol, label, and transparency used.

${location | drawingInfo:"currentLayer"}

You can specify this information either from the current layer or from a specific feature layer through a provided URL. See the Map questions section of the Survey123 Report Templates documentation for more information.


Can reports be created for surveys created in Connect and then linked to an SDE in Enterprise?

Yes.

 
Is there different syntax for reporting the summary of your selected attributes? Max, min, mean of the different features?  

Yes. Check the Summary section of the Survey123 Report syntax help, or check this blog

Upcoming sessions

 

Join us next week to learn about automating Survey123 reports

 

IsmaelChivite_0-1681933601629.png

 

5 Replies
survey123_solutions
Regular Contributor

Excellent resources as always,  IsmaelChivite!! Looking forward to this week's Tips & Tricks session!

EleanorSwensson
Emerging Contributor

Thanks so much for this, @IsmaelChivite ! A follow up to the dynamic visibility question answered above: is it possible to hide a section from view based on the survey response? I.e. switching the syntax logic from showing text if "yes" to hiding text if "no". If so, what would that syntax be?

0 Kudos
IsmaelChivite
Esri Notable Contributor

@EleanorSwensson I am not sure I follow the question. The 'if' operator lets you hide and show sections of your report. Check out this help topic for details: https://doc.arcgis.com/en/survey123/browser/analyze-results/featurereporttemplates.htm#ESRI_SECTION1... 

0 Kudos
MD7
by
New Contributor

@IsmaelChivite is it possible to do something like if - else condition?

For example, $if{inspection_result | selected: 'passed'} Passed Inspection else failed Inspection.

i.e if the condition is true display the text 'Passed inspection' else display the text 'Failed Inspection'

0 Kudos
ChrisBoland
Occasional Contributor

If you're using a select_one type question to say whether the inspection passed or failed, could you use the "checked" method? For example:

${inspection_result | checked:"passed"} Passed Inspection

This would result in a filled checkbox if the inspection_result select_one question's answer was "passed," otherwise, it would be an empty checkbox.

0 Kudos