The image below is a screenshot of 2 objects in an array.
How can I retrieve the dates and the string "" inside this array? Please consider if there is more than 1 object in the array.
I've created this function thus far:
function printData(data) {
$.each(data, function(i, item) {
//console.log(item);
$.each(item, function(j, c) {
//console.log(c);
$.each(c, function(k, l){
//console.log(l.v);
});
});
});
//console.log(data.c.v);
console.dir(data);
}
Can you tweak this function to get what I want.

Edit:
The object:
data = new google.visualization.DataTable();
data.addColumn('datetime', 'start');
data.addColumn('datetime', 'end');
data.addColumn('string', 'content');
A listener lets users to add events to the timeline, and I add the data to the timeline as follows:
var options = {
"width": "100%",
"height": "300px",
"editable": true,
"style": "box"
};
timeline.draw(data, options);
Here is the delete function (may help to distinguish selections of the object):
function doDelete() { /*** Delete the currently selected event */
// retrieve the selected row
var sel = timeline.getSelection();
if (sel.length) {
if (sel[0].row != undefined) {
var row = sel[0].row;
}
}
if (row != undefined) {
timeline.deleteItem(row);
} else {
alert("First select an event, then press remove again");
}
}
console.log(JSON.stringify(data, null, 4));
outputs:
{
"cols": [
{
"id": "",
"label": "start",
"pattern": "",
"type": "datetime"
},
{
"id": "",
"label": "end",
"pattern": "",
"type": "datetime"
},
{
"id": "",
"label": "content",
"pattern": "",
"type": "string"
}
],
"rows": [
{
"c": [
{
"v": "Date(2014, 3, 24)",
"f": null
},
{
"v": "Date(2014, 4, 1)",
"f": null
},
{
"v": "Subgoal A",
"f": null
}
]
},
{
"c": [
{
"v": "Date(2014, 4, 1)",
"f": null
},
{
"v": "Date(2014, 4, 8)",
"f": null
},
{
"v": "Subgoal B",
"f": null
}
]
}
],
"p": null
}