<?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: Calculation not working after using both pulldata() and user entered data - is it my syntax or something else? in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-not-working-after-using-both-pulldata/m-p/866837#M27211</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Robert,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Apologies for the delay. &amp;nbsp;It looks like you have the positive and negative calculations switched in the form - the IF statement in Excel (like XLSForm) has the first outcome being when true and the second when false. &amp;nbsp;Aside from that, I would need to see the Excel sheet you are trying to copy from in order to understand how well the XLSForm meets the formula.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 27 Jul 2020 16:26:19 GMT</pubDate>
    <dc:creator>JamesTedrick</dc:creator>
    <dc:date>2020-07-27T16:26:19Z</dc:date>
    <item>
      <title>Calculation not working after using both pulldata() and user entered data - is it my syntax or something else?</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-not-working-after-using-both-pulldata/m-p/866836#M27210</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a simple survey where my calculations are not working. It is either my syntax for the calculation or where it calculations are in the survey.&amp;nbsp;&lt;/P&gt;&lt;P&gt;The Survey calculates Gallons Per Minute. The user selects a station which uses pulldata() to draw depth and width values from a separate table. Then they enter in two other values for a beginning and ending test dimension. Once the user enters in the two other values, a calculation needs to take place using the pulldata() values and the user entered values.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The equation I am trying to use is the following one out of an Excel spreadsheet.&lt;/P&gt;&lt;P&gt;IF($B$6&amp;gt;0,$B$5*$B$6*(C11-C12)/12*7.48,3.14*($B$5/2)^2*(C11-C12)/12*7.48))&lt;/P&gt;&lt;P&gt;B5 and B6 are pulldata() values in the Survey, C11 and C12 are the user entered values for start/finish dimensions in the Survey.&lt;/P&gt;&lt;P&gt;I know that excel formulas don't translate over to Survey123 completely so I am wondering if my syntax for the equation could be wrong in Survey, or it is how I have it set up that is preventing it from running the calculations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I broke up the excel IF statement into two calculations&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;1. $B$5*$B$6*(C11-C12)/12*7.48&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2. 3.14*($B$5/2)^2*(C11-C12)/12*7.48&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;My versions of the excel formula in Survey&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;1.&amp;nbsp;int(((${well_length}*${well_width})*(${pump1_draw_startlevel}-${pump1_draw_finishlevel})div12)*7.48)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2.&amp;nbsp;int((3.14*(pow((${well_length}div2),2))*(${pump1_draw_startlevel}-${pump1_draw_finishlevel})div12)*7.48)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be appreciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 May 2020 13:41:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/calculation-not-working-after-using-both-pulldata/m-p/866836#M27210</guid>
      <dc:creator>RobertBohon</dc:creator>
      <dc:date>2020-05-19T13:41:27Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation not working after using both pulldata() and user entered data - is it my syntax or something else?</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-not-working-after-using-both-pulldata/m-p/866837#M27211</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Robert,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Apologies for the delay. &amp;nbsp;It looks like you have the positive and negative calculations switched in the form - the IF statement in Excel (like XLSForm) has the first outcome being when true and the second when false. &amp;nbsp;Aside from that, I would need to see the Excel sheet you are trying to copy from in order to understand how well the XLSForm meets the formula.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Jul 2020 16:26:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/calculation-not-working-after-using-both-pulldata/m-p/866837#M27211</guid>
      <dc:creator>JamesTedrick</dc:creator>
      <dc:date>2020-07-27T16:26:19Z</dc:date>
    </item>
  </channel>
</rss>

