Loading array from recordset causing error with line chrt April 17, 2013 07:56PM |
Registered: 11 years ago Posts: 3 |
I am trying to load the array for a simple line chart from a recordset using ASP:
This worked just fine:
X = 1 to start
I've also tried the following for the load line:
And I get the same error:
Message: '0' is null or not an object
Line: 1770
Char: 5
Code: 0
The offending line:
Any help is greatly appreciated!
This worked just fine:
var myMoodData = new Array([1, 1], [2, 0], [3, 2], [4, 2], [5, 1], [6, 2], [7, 1], [8, 1], [9, 1], [10, 2]);
X = 1 to start
var myMoodData = new Array(); <% If Not rsMood.EOF Then %> <% While Not rsMood.EOF %> myMoodData[<%= x %>]="<%= CondInt(rsMood("MoodValue" )) %>"; //space inserted to keep a winkie face from showing up! <% x = x + 1 %> <% rsMood.MoveNext %> <% Wend %> <% End If %>
I've also tried the following for the load line:
myMoodData[<%= x %>]=<%= CondInt(rsMood("MoodValue" )) %>; myMoodData[<%= x %>,<%= CondInt(rsMood("MoodValue" )) %>];
And I get the same error:
Message: '0' is null or not an object
Line: 1770
Char: 5
Code: 0
The offending line:
var myMoodChart = new JSChart('graph', 'line'); -->> myMoodChart.setDataArray(myMoodData); <<--
Any help is greatly appreciated!
Re: Loading array from recordset causing error with line chrt April 19, 2013 04:59PM |
Registered: 11 years ago Posts: 3 |
Sorry, you do not have permission to post/reply in this forum.