<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Using the &amp;quot;if(selected&amp;quot; function with &amp;quot;indexed-repeats&amp;quot; to pull data from any created repeat in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/using-the-quot-if-selected-quot-function-with-quot/m-p/1184057#M43317</link>
    <description>&lt;P&gt;Hi I'm working in S123, and I am making a relatively simple repeating data sheet to collect wildlife cam data.&lt;/P&gt;&lt;P&gt;However, I was hoping to make a summary checklist based on the cameras that have data collected, which will allow the field techs an easy check to see which cameras are completed. Below is the desired effect (A1 was filled out).&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="GBerry_0-1655498815642.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43759i4C22A414821FD784/image-size/medium?v=v2&amp;amp;px=400" role="button" title="GBerry_0-1655498815642.png" alt="GBerry_0-1655498815642.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was able to do this when the data collection was not in the repeat format by using:&lt;/P&gt;&lt;P&gt;Type&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; name&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; label&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; calculation&lt;/P&gt;&lt;TABLE width="1042px"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="146px"&gt;note&lt;/TD&gt;&lt;TD width="163px"&gt;camera_A1&lt;/TD&gt;&lt;TD width="456px"&gt;&amp;lt;body bgcolor=${camera_A1_color}&amp;gt;&amp;lt;font color="black"&amp;gt;&amp;lt;b&amp;gt;A1&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;/body&amp;gt;&lt;/TD&gt;&lt;TD width="277px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="146px"&gt;calculate&lt;/TD&gt;&lt;TD width="163px"&gt;camera_A1_color&lt;/TD&gt;&lt;TD width="456px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="277px"&gt;if(selected(${A1_camera_on}, 'yes'), "#5ac18e", "#E7E7E7")&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I changed the form around a bit and the selection to&amp;nbsp; ${camera_ID}, 'A1' which worked fine.&lt;/P&gt;&lt;P&gt;But now that it's in repeats, only the currently visible form is highlighting.&lt;/P&gt;&lt;P&gt;I've tried using script with iterations of:&lt;/P&gt;&lt;P&gt;calculation&lt;/P&gt;&lt;TABLE width="590"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="590"&gt;if(selected(indexed-repeat(${camera_ID}, 'A1',${camera_repeat}, n)),&amp;nbsp; "#5ac18e", "#E7E7E7")&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;But the indexed-repeat does not seem to like the fact there's the 'A1' there.&lt;/P&gt;&lt;P&gt;And I'm also not sure if n is a proper way to say 'all repeats' or if 'all repeats' is possible.&lt;/P&gt;&lt;P&gt;Any help or guidance would be much appreciated!&lt;/P&gt;</description>
    <pubDate>Fri, 17 Jun 2022 20:56:47 GMT</pubDate>
    <dc:creator>GBerry</dc:creator>
    <dc:date>2022-06-17T20:56:47Z</dc:date>
    <item>
      <title>Using the "if(selected" function with "indexed-repeats" to pull data from any created repeat</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/using-the-quot-if-selected-quot-function-with-quot/m-p/1184057#M43317</link>
      <description>&lt;P&gt;Hi I'm working in S123, and I am making a relatively simple repeating data sheet to collect wildlife cam data.&lt;/P&gt;&lt;P&gt;However, I was hoping to make a summary checklist based on the cameras that have data collected, which will allow the field techs an easy check to see which cameras are completed. Below is the desired effect (A1 was filled out).&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="GBerry_0-1655498815642.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43759i4C22A414821FD784/image-size/medium?v=v2&amp;amp;px=400" role="button" title="GBerry_0-1655498815642.png" alt="GBerry_0-1655498815642.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was able to do this when the data collection was not in the repeat format by using:&lt;/P&gt;&lt;P&gt;Type&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; name&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; label&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; calculation&lt;/P&gt;&lt;TABLE width="1042px"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="146px"&gt;note&lt;/TD&gt;&lt;TD width="163px"&gt;camera_A1&lt;/TD&gt;&lt;TD width="456px"&gt;&amp;lt;body bgcolor=${camera_A1_color}&amp;gt;&amp;lt;font color="black"&amp;gt;&amp;lt;b&amp;gt;A1&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;/body&amp;gt;&lt;/TD&gt;&lt;TD width="277px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="146px"&gt;calculate&lt;/TD&gt;&lt;TD width="163px"&gt;camera_A1_color&lt;/TD&gt;&lt;TD width="456px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="277px"&gt;if(selected(${A1_camera_on}, 'yes'), "#5ac18e", "#E7E7E7")&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I changed the form around a bit and the selection to&amp;nbsp; ${camera_ID}, 'A1' which worked fine.&lt;/P&gt;&lt;P&gt;But now that it's in repeats, only the currently visible form is highlighting.&lt;/P&gt;&lt;P&gt;I've tried using script with iterations of:&lt;/P&gt;&lt;P&gt;calculation&lt;/P&gt;&lt;TABLE width="590"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="590"&gt;if(selected(indexed-repeat(${camera_ID}, 'A1',${camera_repeat}, n)),&amp;nbsp; "#5ac18e", "#E7E7E7")&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;But the indexed-repeat does not seem to like the fact there's the 'A1' there.&lt;/P&gt;&lt;P&gt;And I'm also not sure if n is a proper way to say 'all repeats' or if 'all repeats' is possible.&lt;/P&gt;&lt;P&gt;Any help or guidance would be much appreciated!&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 20:56:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/using-the-quot-if-selected-quot-function-with-quot/m-p/1184057#M43317</guid>
      <dc:creator>GBerry</dc:creator>
      <dc:date>2022-06-17T20:56:47Z</dc:date>
    </item>
    <item>
      <title>Re: Using the "if(selected" function with "indexed-repeats" to pull data from any created repeat</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/using-the-quot-if-selected-quot-function-with-quot/m-p/1184088#M43320</link>
      <description>&lt;P&gt;Or in other words how can I combine this line of code:&lt;/P&gt;&lt;P&gt;if(selected(${camera_ID}, 'A1'), "#5ac18e", "#E7E7E7")&lt;/P&gt;&lt;P&gt;With every repeat that's been taken.&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 22:51:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/using-the-quot-if-selected-quot-function-with-quot/m-p/1184088#M43320</guid>
      <dc:creator>GBerry</dc:creator>
      <dc:date>2022-06-17T22:51:34Z</dc:date>
    </item>
    <item>
      <title>Re: Using the "if(selected" function with "indexed-repeats" to pull data from any created repeat</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/using-the-quot-if-selected-quot-function-with-quot/m-p/1185103#M43376</link>
      <description>&lt;P&gt;I would create a field that concatenates all of your camera ids into a single field outside of your repeat using&amp;nbsp;&lt;STRONG&gt;join(',', ${camera_ID})&lt;/STRONG&gt;. Then change your if statements to&amp;nbsp;&lt;STRONG&gt;if(contains(${cameras_joined}, 'A1'),&amp;nbsp;'#5ac18e', '#E7E7E7')&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Jun 2022 15:48:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/using-the-quot-if-selected-quot-function-with-quot/m-p/1185103#M43376</guid>
      <dc:creator>JenniferAcunto</dc:creator>
      <dc:date>2022-06-22T15:48:54Z</dc:date>
    </item>
  </channel>
</rss>

