<?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 Re: Constraining a Geopoint answer to a given area. in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1226828#M45719</link>
    <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/528945"&gt;@RogerAsbury&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;&lt;P&gt;One option would be to use the new &lt;A href="https://community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-pulldata-quot-layer/bc-p/1226159#M5285" target="_self"&gt;pulldata&amp;nbsp;@layer functionality&lt;/A&gt; we just implemented with our 3.16 release. Assuming you have a previous question that requests for the service area you can use pulldata&amp;nbsp;@layer to do a point in polygon lookup and verify that the location set in the geopoint is identical to the service area selected. That way your constraint would just need to be ${questionA}=${calculationA}.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please see this survey for a live example:&amp;nbsp;&lt;A href="https://arcg.is/1braCn" target="_blank" rel="noopener"&gt;https://arcg.is/1braCn&lt;/A&gt;&lt;/P&gt;&lt;P&gt;If you select a state from the drop down list a geopoint question will then become relevant, if your geopoint location doesn't reside in the state you selected then a constraint will prevent submission, otherwise if you select the state your geopoint resides in you can submit the survey.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Source XLSForm is attached below.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 28 Oct 2022 23:03:58 GMT</pubDate>
    <dc:creator>ZacharySutherby</dc:creator>
    <dc:date>2022-10-28T23:03:58Z</dc:date>
    <item>
      <title>Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1226819#M45718</link>
      <description>&lt;P&gt;I appear to be full of Survey123 questions lately. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Given a survey with a map that has a layer defining a service area (example below) how can you confine answers (map points) that are within that polygon shape? What if there are multiple unconnected polygons? I've seen a few answers for creating single, rectangular constraints, but can't seem to find info on polygons. And I've seen nothing on creating multiples, if you have several, unconnected, areas.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Road service areas." style="width: 615px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/54754i09FFFF9CE2018373/image-size/large?v=v2&amp;amp;px=999" role="button" title="confinetoarea.png" alt="Road service areas." /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Road service areas.&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Oct 2022 22:23:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1226819#M45718</guid>
      <dc:creator>RogerAsbury</dc:creator>
      <dc:date>2022-10-28T22:23:43Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1226828#M45719</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/528945"&gt;@RogerAsbury&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;&lt;P&gt;One option would be to use the new &lt;A href="https://community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-pulldata-quot-layer/bc-p/1226159#M5285" target="_self"&gt;pulldata&amp;nbsp;@layer functionality&lt;/A&gt; we just implemented with our 3.16 release. Assuming you have a previous question that requests for the service area you can use pulldata&amp;nbsp;@layer to do a point in polygon lookup and verify that the location set in the geopoint is identical to the service area selected. That way your constraint would just need to be ${questionA}=${calculationA}.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please see this survey for a live example:&amp;nbsp;&lt;A href="https://arcg.is/1braCn" target="_blank" rel="noopener"&gt;https://arcg.is/1braCn&lt;/A&gt;&lt;/P&gt;&lt;P&gt;If you select a state from the drop down list a geopoint question will then become relevant, if your geopoint location doesn't reside in the state you selected then a constraint will prevent submission, otherwise if you select the state your geopoint resides in you can submit the survey.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Source XLSForm is attached below.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Oct 2022 23:03:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1226828#M45719</guid>
      <dc:creator>ZacharySutherby</dc:creator>
      <dc:date>2022-10-28T23:03:58Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1226830#M45721</link>
      <description>&lt;P&gt;Awesome! Thanks much for pointing me that way. Been wondering this for a bit. Glad to see something was recently posted. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Oct 2022 23:14:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1226830#M45721</guid>
      <dc:creator>RogerAsbury</dc:creator>
      <dc:date>2022-10-28T23:14:04Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1227040#M45742</link>
      <description>&lt;P&gt;I have also done the low tech way.&amp;nbsp; Read the lat and long into a field using pulldata then set a constraint on those numbers.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also have done it where it passes in the lat/long the crews are supposed to try and get to into the form from Field Maps.&amp;nbsp; Then I use a calc to see how far their current location is from where they are supposed to be.&amp;nbsp; As they refresh the map question the distance updates.&amp;nbsp; Then I can set a constraint on that distance.&amp;nbsp; Worked out well.&lt;/P&gt;</description>
      <pubDate>Mon, 31 Oct 2022 14:08:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1227040#M45742</guid>
      <dc:creator>DougBrowning</dc:creator>
      <dc:date>2022-10-31T14:08:54Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1282391#M48873</link>
      <description>&lt;P&gt;How is this done if it is only based on location and not an input question value? I used a point in the same buffer polygon to add Name value to the new point feature, but I need to constrain the point location within the same buffer polygon feature service (contains several polygons). The example shown is the functionality I need but I need help finding the right way to set it up.&lt;/P&gt;</description>
      <pubDate>Tue, 25 Apr 2023 15:49:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1282391#M48873</guid>
      <dc:creator>TeresaWhitney</dc:creator>
      <dc:date>2023-04-25T15:49:01Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1330620#M51843</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/6891"&gt;@TeresaWhitney&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm wondering if you came across any other information on how to do this. I'm working on a project where I'm hoping to implement a geopoint question that checks if the point is within a polygon on the basemap.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Sep 2023 14:32:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1330620#M51843</guid>
      <dc:creator>AmandaBeck</dc:creator>
      <dc:date>2023-09-20T14:32:59Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1331062#M51875</link>
      <description>&lt;P&gt;I did get information at the Esri users conference to make this work. It was the constraint part setup that I had been missing.&amp;nbsp;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;First calculate a text question to get a value from your polygon using the location&lt;/LI&gt;&lt;OL&gt;&lt;LI&gt;&lt;A href="https://urldefense.com/v3/__https:/doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformformulas.htm*ESRI_SECTION1_BB97985CAFB740EE8AEF99EFD6E238E3__;Iw!!GzRj30k!W_bFQlP6nXPubx2EMbxnYpAVpOKLmW4Z2tJxiieafAmKnE46ctgKAtxw4gOSGAVumIcPrDlWFL73mbqz-3Q$" target="_blank"&gt;https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformformulas.htm#ESRI_SECTION1_BB97985CAFB740EE8AEF99EFD6E238E3&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;&lt;A href="https://urldefense.com/v3/__https:/community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-pulldata-quot-layer/ba-p/1224415__;!!GzRj30k!W_bFQlP6nXPubx2EMbxnYpAVpOKLmW4Z2tJxiieafAmKnE46ctgKAtxw4gOSGAVumIcPrDlWFL73EPj1w0Y$" target="_blank"&gt;https://community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-pulldata-quot-layer/ba-p/1224415&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;Or you can do this calculation in web designer and then download the survey into Connect to look at the syntax&lt;/LI&gt;&lt;/OL&gt;&lt;LI&gt;In the constraint column of your geopoint question, check if the value above is empty&lt;/LI&gt;&lt;OL&gt;&lt;LI&gt;string-length(${&amp;lt;myquestionNamehere&amp;gt;})&amp;gt;0&lt;/LI&gt;&lt;LI&gt;Also add a constraint message&lt;/LI&gt;&lt;/OL&gt;&lt;LI&gt;For the question that is calculated with the point in poly query, set the value in appearance to hidden and the value in esriFieldType to null&lt;/LI&gt;&lt;/OL&gt;</description>
      <pubDate>Thu, 21 Sep 2023 14:34:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1331062#M51875</guid>
      <dc:creator>TeresaWhitney</dc:creator>
      <dc:date>2023-09-21T14:34:44Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1516072#M58363</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/251557"&gt;@ZacharySutherby&lt;/a&gt;, thanks for this solution. I have been using it in some of my forms. I am using the exact same methodology as you, but I'm finding that the constraint text is still showing up even if the constraint is fulfilled. See example below - the point is in Maryland but you can see the red text. Note this happens occasionally. When this happens, it does not prevent submitting the form, but can cause confusion for our users which we do not want. Do you have any suggestions?&lt;/P&gt;&lt;P&gt;Initially I was using the USA census states layer but switched to generalized boundaries layer as yours used. I thought that resolved the issue (i.e., attribute comparison processed more quickly) but I'm still seeing the constraint text remain.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Tiff_0-1723037667695.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/111833iB90BFBB1E0DE16B9/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Tiff_0-1723037667695.png" alt="Tiff_0-1723037667695.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 07 Aug 2024 13:35:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1516072#M58363</guid>
      <dc:creator>Tiff</dc:creator>
      <dc:date>2024-08-07T13:35:59Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1537332#M59070</link>
      <description>&lt;P&gt;This is the answer!&amp;nbsp; Thank you so much.&amp;nbsp; One other caveat is that the layer being accessed by the pulldata line in the constrain column must be public, or else it will not be accessible to the pulldata command.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Sep 2024 14:36:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1537332#M59070</guid>
      <dc:creator>JamesSerendip1</dc:creator>
      <dc:date>2024-09-11T14:36:09Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1609734#M62285</link>
      <description>&lt;P&gt;I think my answer is in&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/6891"&gt;@TeresaWhitney&lt;/a&gt;'s references, but I haven't been able to work it out. I have a survey, created in Survey123 Connect, with a geopoint question "location". I also have a feature layer with our city boundary shared publicly. There's only one poly in the layer and the only fields are shape length, shape area, and OBJECTID. I want to constrain points to that polygon. The examples use a country layer from Living Atlas and refer to the individual polygon by finding a value in a field (country='Canada').&lt;/P&gt;&lt;P&gt;What do I need to do to constrain the geopoint to the single polygon in my feature layer? Seems like I need a question with a calculation to get the record of the polygon and a constraint on the geopoint that the location is within the polygon. Can anyone provide some help with that syntax, and let me know if I'm missing something else?&lt;/P&gt;</description>
      <pubDate>Mon, 28 Apr 2025 18:01:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1609734#M62285</guid>
      <dc:creator>BrianShepard</dc:creator>
      <dc:date>2025-04-28T18:01:23Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1609931#M62299</link>
      <description>&lt;P&gt;Check out pulldata&amp;nbsp; &amp;nbsp;&lt;A href="https://community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-pulldata-quot-layer/ba-p/1224415" target="_blank"&gt;https://community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-pulldata-quot-layer/ba-p/1224415&lt;/A&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Apr 2025 13:21:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1609931#M62299</guid>
      <dc:creator>DougBrowning</dc:creator>
      <dc:date>2025-04-29T13:21:56Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1610024#M62310</link>
      <description>&lt;P&gt;I have, it didn't help me. All of the examples I've come across use a string field to specify a polygon within a feature layer to use for the constraint. The layer I'd like to use has a single polygon and no string fields. I've tried using the OBJECTID value, but get an error that it's not a string.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Apr 2025 15:11:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1610024#M62310</guid>
      <dc:creator>BrianShepard</dc:creator>
      <dc:date>2025-04-29T15:11:29Z</dc:date>
    </item>
    <item>
      <title>Re: Constraining a Geopoint answer to a given area.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1610392#M62336</link>
      <description>&lt;P&gt;You may be able to check for empty list.&amp;nbsp; If it finds nothing its empty and set a constraint on that.&amp;nbsp; Also could try making pulldata field an int.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Apr 2025 14:26:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/constraining-a-geopoint-answer-to-a-given-area/m-p/1610392#M62336</guid>
      <dc:creator>DougBrowning</dc:creator>
      <dc:date>2025-04-30T14:26:39Z</dc:date>
    </item>
  </channel>
</rss>

