Open GoogleCodeExporter opened 9 years ago
Original comment by fg.mag...@gmail.com
on 8 Apr 2010 at 9:21
Insert this code after 286 line:
/**
* This checking is important if all of the data value in the table is 0.
*/
if(typeof(points[0]) == 'undefined' && points[0] == null) {
points[0]=0;
}
if(!isFinite(yScale)) yScale=0;
Then try to find this row:
var zeroLoc = o.height * (topValue/totalYRange);
And insert this:
/**
* This checking is important if all of the data value in the table is 0.
*/
if((typeof(zeroLoc) == 'undefined' && zeroLoc == null) || isNaN(zeroLoc)) {
zeroLoc = 0;
}
Br,
Tamas
Original comment by tamas....@eldanor.hu
on 16 Apr 2010 at 3:38
Hello! Great plugin. But I'll have a use case that initially all tables are
filled with 0 values. I tried to make changes to the code as mentioned above
but still get this error in firebug:
An invalid or illegal string was specified" code: "12
[Break On This Error] ctx.translate(0,zeroLoc);
Any ideas? Thanks, Sev
Original comment by ego...@gmail.com
on 5 Jan 2011 at 11:28
i just tried the suggestion above and it worked great. I originally put the
first section of code at line 286 as suggested, but it didn't work. put it
between the "var integer = 0;" and the "ctx.moveTo(0,-(points[0]*yScale));"
lines.
*** 289,294 ****
--- 289,301 ----
ctx.lineJoin = 'round';
var points = this.points;
var integer = 0;
+ /**
+ * This checking is important if all of
the data value in the table is 0.
+ */
+ if(typeof(points[0]) == 'undefined' &&
points[0] == null) {
+ points[0]=0;
+ }
+ if(!isFinite(yScale)) yScale=0;
ctx.moveTo(0,-(points[0]*yScale));
$.each(points, function(){
ctx.lineTo(integer,-(this*yScale));
***************
*** 404,409 ****
--- 411,422 ----
var memberTotals = tableData.memberTotals();
var totalYRange = tableData.totalYRange();
var zeroLoc = o.height * (topValue/totalYRange);
+ /**
+ * This checking is important if all of the data value in the
table is 0.
+ */
+ if((typeof(zeroLoc) == 'undefined' && zeroLoc == null) ||
isNaN(zeroLoc)) {
+ zeroLoc = 0;
+ }
var xLabels = tableData.xLabels();
var yLabels = tableData.yLabels();
Original comment by anthony%...@gtempaccount.com
on 10 Jan 2011 at 4:11
Thanks for your input. This worked for me! No more errors :)
Regards,
sev
Original comment by ego...@gmail.com
on 10 Jan 2011 at 9:34
[deleted comment]
I got the same problem in Firefox 3.6.13 on Windows Vista. I only have 1 set of
data, I'm trying to show 1 line in my line diagram and this crashes the code on
line 284, it says
An invalid or illegal string was specified" code: "12
ctx.translate(0,zeroLoc);
As previously stated. But the problem is that my chart is completely empty, no
line shows up at all. If I use the hack previously posted in this thread I get
rid of the error, but my chart is still empty. It works in Chrome, Safari and
IE8. Any suggestions?
Original comment by stefanko...@gmail.com
on 17 Feb 2011 at 8:42
@stefanko Use jquery 1.4.2 and it will probably work. At least it does for me.
Any higher than that results in an empty graph area. No graph and not even the
grid lines will show.
Original comment by citsdoti...@gmail.com
on 8 Apr 2011 at 1:55
Yes, http://code.google.com/p/dwpe/issues/detail?id=12#c4 worked perfectly.
Thanks
Original comment by alex.joh...@gmail.com
on 9 Jun 2011 at 12:46
[deleted comment]
I have tried above comment#4. It doesn't work in IE browser
Original comment by nighthaw...@gmail.com
on 25 Jul 2011 at 7:36
Attachments:
I have the same problem, shows zeros but only shows the table caption.
I added the following lines:
//get title for chart
var title = o.title || self.find('caption').text();
alert('o title ' + o.title);
alert('selft caption ' + self.find('caption').text());
And there's something interesting, o is NULL .... author please comment !!
I'm using IE 8 and IIS 7 server on windows7.
Original comment by fernando...@gmail.com
on 9 Nov 2012 at 4:19
Ok I did this fix to the visualize .js:
Eliminated all .filter(o.colFilter) and .filter(o.rowFilter) from the script
and graphic is now working good..
Original comment by fernando...@gmail.com
on 9 Nov 2012 at 2:19
Original issue reported on code.google.com by
froschla...@googlemail.com
on 1 Apr 2010 at 3:16