-1

idea is expected to find Max Date in Jqx widgets grid

Date Column

05/11/2016, 10/11/2016, 15/11/2016, 20/11/2016

output

20/11/2016

Here is My Code:

$.each(data1, function (idx, value) { var dates = []; dates.push(new Date(dt)); var maxDate = new Date(Math.max.apply(null, dates)); });

alert(maxDate)
DanielBarbarian
  • 5,093
  • 12
  • 35
  • 44
yuvi
  • 1
  • 5

1 Answers1

0

how about this one ?

var dates = [];   
$.each(data1, function (idx, value) {   
   dates.push(new Date(dt)); 
});

var maxDate = new Date(Math.max.apply(null, dates)); 

alert(maxDate);
Ivan
  • 96
  • 2
  • 8