<?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: Adding TimeSlider: &amp;quot;results is not defined&amp;quot; in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200006#M18514</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Don,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Try using either Firebug or Chrome Developer tools to add a breakpoint at the line in your code where you are trying to get features1.timeInfo. After setting a breakpoint you can inspect features1 and check the value to see if it has a value for the timeInfo property.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kelly&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 03 Oct 2012 20:04:18 GMT</pubDate>
    <dc:creator>KellyHutchins</dc:creator>
    <dc:date>2012-10-03T20:04:18Z</dc:date>
    <item>
      <title>Adding TimeSlider: &amp;amp;amp;quot;results is not defined&amp;amp;amp;quot;</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200001#M18509</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am trying to add a TimeSlider to an app that includes a time-aware feature layer. I have carefully read the reference doc (&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://help.arcgis.com/en/webapi/javascript/arcgis/help/jshelp_start.htm#jshelp/inside_temporal.htm" rel="nofollow" target="_blank"&gt;http://help.arcgis.com/en/webapi/javascript/arcgis/help/jshelp_start.htm#jshelp/inside_temporal.htm&lt;/A&gt;&lt;SPAN&gt;) and copied the sample code into my page, as well as looking at some of the working examples. But when the page loads the slider does not initiate, and the js console shows the error "results is not defined". What am I not doing?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You can see the app here: &lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://www.facstaff.bucknell.edu/rea/map.html" rel="nofollow" target="_blank"&gt;http://www.facstaff.bucknell.edu/rea/map.html&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Oct 2012 14:16:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200001#M18509</guid>
      <dc:creator>DonRea</dc:creator>
      <dc:date>2012-10-02T14:16:49Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200002#M18510</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Don,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In your app you are accessing the variable results before it is defined. In this line you want to get the time info from the layer so perhaps you mean feature1 instead of results[1].layer? Looks like feature1 is the time-aware layer in your app. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; var layerTimeExtent = results [1].layer.timeInfo.timeExtent;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Oct 2012 18:23:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200002#M18510</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2012-10-02T18:23:24Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200003#M18511</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm afraid I have no idea what I want. I just copied the code from the examples...When is 'results' defined? What is it? And how does one find out things like that? My experience with the documentation so far has been pretty frustrating.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In any case, trying to refer to features1.timeExtent results in this message in the js console: "TimeExtent not specified, or in incorrect format." According to the map service:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Time Info:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Start Time Field: PERMITYEAR_TimeSliderDATE &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Time Field: null &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Track ID Field: null &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Time Extent:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[1999/01/01 00:00:00 UTC, 2010/01/01 00:00:00 UTC]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Time Reference: N/A &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Time Interval: 1 &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Time Interval Units: esriTimeUnitsYears &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Has Live Data: false &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Export Options:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Use Time: true &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Time Data Cumulative: true &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Time Offset: null (null)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there something wrong here?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Oct 2012 18:49:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200003#M18511</guid>
      <dc:creator>DonRea</dc:creator>
      <dc:date>2012-10-02T18:49:46Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200004#M18512</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Try features1.timeInfo.timeExtent.&amp;nbsp; In your code features1 is a feature layer so you can use the timeInfo property to access details about the layer's time properties. See the feature layer api reference for info:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi/featurelayer.htm"&gt;http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi/featurelayer.htm&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'd have to know which sample you copied the code from to be sure but I suspect that results is the argument in the onLayersAddResult event handler. If that's the case the results would refer to the layers that were added to the map with the addLayers method. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;I'm afraid I have no idea what I want. I just copied the code from the examples...When is 'results' defined? What is it? And how does one find out things like that? My experience with the documentation so far has been pretty frustrating.&lt;BR /&gt;&lt;BR /&gt;In any case, trying to refer to features1.timeExtent results in this message in the js console: "TimeExtent not specified, or in incorrect format." According to the map service:&lt;BR /&gt;&lt;BR /&gt;Time Info:&lt;BR /&gt;Start Time Field: PERMITYEAR_TimeSliderDATE &lt;BR /&gt;End Time Field: null &lt;BR /&gt;Track ID Field: null &lt;BR /&gt;Time Extent:&lt;BR /&gt;[1999/01/01 00:00:00 UTC, 2010/01/01 00:00:00 UTC]&lt;BR /&gt;&lt;BR /&gt;Time Reference: N/A &lt;BR /&gt;Time Interval: 1 &lt;BR /&gt;Time Interval Units: esriTimeUnitsYears &lt;BR /&gt;Has Live Data: false &lt;BR /&gt;Export Options:&lt;BR /&gt;Use Time: true &lt;BR /&gt;Time Data Cumulative: true &lt;BR /&gt;Time Offset: null (null)&lt;BR /&gt;&lt;BR /&gt;Is there something wrong here?&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Oct 2012 19:06:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200004#M18512</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2012-10-02T19:06:13Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200005#M18513</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Now I'm really confused. When I refer to features1.timeInfo.timeExtent, I'm seeing the error "features1.timeInfo is undefined", even though the time info I posted above is copied directly from viewing the service in my browser.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 11:54:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200005#M18513</guid>
      <dc:creator>DonRea</dc:creator>
      <dc:date>2012-10-03T11:54:25Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200006#M18514</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Don,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Try using either Firebug or Chrome Developer tools to add a breakpoint at the line in your code where you are trying to get features1.timeInfo. After setting a breakpoint you can inspect features1 and check the value to see if it has a value for the timeInfo property.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kelly&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 20:04:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200006#M18514</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2012-10-03T20:04:18Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200007#M18515</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Kelly,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm sorry, I wasn't clear. At that point, features1 doesn't even have a timeInfo property. I guess what I'm asking is, why doesn't initializing a featureLayer object with a time-enabled feature layer from the map service include the time information? What else do I not yet know I need to do?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Oct 2012 13:31:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200007#M18515</guid>
      <dc:creator>DonRea</dc:creator>
      <dc:date>2012-10-04T13:31:21Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200008#M18516</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Try moving the logic that gets the timeInfo into the initSlider function. It may be that you are trying to access the timeInfo before the layer has loaded:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;

&amp;nbsp;&amp;nbsp;&amp;nbsp; function initSlider (results)
&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; var slider = new esri.dijit.TimeSlider ({}, dojo.byId ('sliderDiv'));
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; map.setTimeSlider (slider);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //&amp;nbsp; var layerTimeExtent = results [1].layer.timeInfo.timeExtent;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var layerTimeExtent = features1.timeInfo.timeExtent;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; slider.createTimeStopsByTimeInterval (layerTimeExtent, 1, 'esriTimeUnitsYears');
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; slider.singleThumbAsTimeInstant (false);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; slider.startup();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; }

&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 09:58:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200008#M18516</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2021-12-11T09:58:10Z</dc:date>
    </item>
    <item>
      <title>Re: Adding TimeSlider: "results is not defined"</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200009#M18517</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;And, thank you!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Oct 2012 16:29:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/adding-timeslider-amp-amp-amp-quot-results-is-not/m-p/200009#M18517</guid>
      <dc:creator>DonRea</dc:creator>
      <dc:date>2012-10-04T16:29:35Z</dc:date>
    </item>
  </channel>
</rss>

