title: SCRIPT28: Out of stack space
body: <p>Getting stack out of space in IE 10,11 when I try encode a array of data to Json and store it into an array</p>
  
  <pre class="lang-js prettyprint-override"><code>var SelPeriod = Ext.getCmp('SelectedPeriodGrid');
  
  SelPerioddata = [];
  
  var PeriodsSelected = SelPeriod.getStore('MarkettrackDrillDownPeriods').getRange();
  
  for (var i = 0; i &lt; PeriodsSelected.length; i++) {
      SelPerioddata.push(PeriodsSelected[i]);
  }
  var SelPerioddatajson = [];
  
  SelPerioddatajson = Ext.JSON.encod(SelPerioddata);
  </code></pre>