<?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 Restrict date values for 99-99-9999 body::esri:inputMask. in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/restrict-date-values-for-99-99-9999-body-esri/m-p/1547723#M59592</link>
    <description>&lt;P&gt;Hi!&amp;nbsp;&lt;BR /&gt;Mi users are filling out a date, to get an easier way to capture it, the field was set up like this&amp;nbsp;99-99-9999 as&amp;nbsp;body::esri:inputMask.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Analyzing the data I've found out that the users sometimes make mistakes, and registered mistmatched dates like 2220 instead of 2020, same thing at months and days.&amp;nbsp;&lt;/P&gt;&lt;P&gt;¿Is there a way to restrict allowed values?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Like, 01 to 31 for 2 first digits, 01 to 12 for second pair of digits and 1900 to 2020 for las 4 digits.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
    <pubDate>Thu, 10 Oct 2024 19:02:21 GMT</pubDate>
    <dc:creator>achs</dc:creator>
    <dc:date>2024-10-10T19:02:21Z</dc:date>
    <item>
      <title>Restrict date values for 99-99-9999 body::esri:inputMask.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/restrict-date-values-for-99-99-9999-body-esri/m-p/1547723#M59592</link>
      <description>&lt;P&gt;Hi!&amp;nbsp;&lt;BR /&gt;Mi users are filling out a date, to get an easier way to capture it, the field was set up like this&amp;nbsp;99-99-9999 as&amp;nbsp;body::esri:inputMask.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Analyzing the data I've found out that the users sometimes make mistakes, and registered mistmatched dates like 2220 instead of 2020, same thing at months and days.&amp;nbsp;&lt;/P&gt;&lt;P&gt;¿Is there a way to restrict allowed values?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Like, 01 to 31 for 2 first digits, 01 to 12 for second pair of digits and 1900 to 2020 for las 4 digits.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 10 Oct 2024 19:02:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/restrict-date-values-for-99-99-9999-body-esri/m-p/1547723#M59592</guid>
      <dc:creator>achs</dc:creator>
      <dc:date>2024-10-10T19:02:21Z</dc:date>
    </item>
    <item>
      <title>Re: Restrict date values for 99-99-9999 body::esri:inputMask.</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/restrict-date-values-for-99-99-9999-body-esri/m-p/1547734#M59593</link>
      <description>&lt;P&gt;I'd do the following:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Make the question type Date (and use the field bindings if the field is something else like string)&lt;/LI&gt;&lt;LI&gt;Set the question appearance to help user input&amp;nbsp;&lt;/LI&gt;&lt;LI&gt;Add a constraint to enforce the desired date range&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;A href="https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformsappearance.htm#ESRI_SECTION1_FB9EDA4925B74091A0CA43C3ADB1C230" target="_blank"&gt;https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformsappearance.htm#ESRI_SECTION1_FB9EDA4925B74091A0CA43C3ADB1C230&lt;/A&gt;&lt;/P&gt;&lt;P&gt;The below blog has more on working with date and time in survey123. You'll want to look at the calculations for the constraint.&lt;/P&gt;&lt;P&gt;If you are trying to submit a string value you might need to set up a dummy user input question for date (null), then calculate the desired date format into the hidden actual string question.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/t5/arcgis-survey123-blog/dates-and-time-in-survey123/ba-p/895528" target="_blank"&gt;https://community.esri.com/t5/arcgis-survey123-blog/dates-and-time-in-survey123/ba-p/895528&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Let us know if this approach doesn't work for your workflow but personally I'd do this over regex and constraint masks...&lt;/P&gt;</description>
      <pubDate>Thu, 10 Oct 2024 19:21:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/restrict-date-values-for-99-99-9999-body-esri/m-p/1547734#M59593</guid>
      <dc:creator>ChristopherCounsell</dc:creator>
      <dc:date>2024-10-10T19:21:54Z</dc:date>
    </item>
  </channel>
</rss>

