We are using a simple line chart to display data.
Generally its perfect, however I have 2 specific computers on the latest
version of chrome where the chart does not load.
It does not throw any Jacascript error, its simply doesn't load.
I've pasted the code below.
Can you advise if this may be related to the browser- and what can be done
to rectify.
Thank you.
function drawTemperatureChart(JSONData, buildingID, virtualID,
fromDate) {
var year = fromDate.split('-')[0];
var month = fromDate.split('-')[1];
var date = fromDate.split('-')[2];
var dateSelected = new Date(year, month - 1, date);
var prevDate = new Date(dateSelected - (1000 * 60 * 60 *
24));//1000 ms * 60 sec * 60 min * 24 hours
try {
var data = new google.visualization.DataTable(JSONData);
var minPipe = data.getColumnRange(1).min;
var minRoom = data.getColumnRange(2).min;
var minY = Math.min(minPipe, minRoom) - 15;
}
catch (err) {
alert(err);
}
var options_lines = {
curveType: 'function',
backgroundColor: 'transparent',
axisTitlesPosition: 'out',
chartArea: {
width: '95%',
height: '75%',
right: 20,
//bottom: -30
},
legend: { position: 'none' },
interpolateNulls: true,
hAxis: {
textPosition: 'bottom',
format:'haa',
textStyle: {
color: '#b1b1b1',
fontSize: 9
},
gridlines: {
color: 'transparent',
count: 15
},
viewWindow: {
min: new Date(prevDate.getFullYear(),
prevDate.getMonth(), prevDate.getDate(), 22, 00),
max: new Date(dateSelected.getFullYear(),
dateSelected.getMonth(), dateSelected.getDate(), 23, 59)
}
},
vAxis: {
textStyle: {
fontSize: 11
},
viewWindow: {
min: minY
}
}
};
try {
var chart_lines = new
google.visualization.LineChart(document.getElementById('tempChart_' +
buildingID + '_' + virtualID));
}
catch (err) {
alert(err);
}
chart_lines.draw(data, options_lines);
)
--
You received this message because you are subscribed to the Google Groups
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit
https://groups.google.com/d/msgid/google-visualization-api/76d04b31-31e3-4de6-a0cd-cc68dc8ad116%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.