MSChart and JavaScript

N

NvrBst

I can't seem to set the "MSChart1.ChartData = myArr;" value using
JavaScript. It says "Bad Argument".

I've tried setting myArr two ways. 1. var myArr = [1,2,3,4,5]; and 2.
var x = [1,2,3,4,5]; var myArr = [x];. Both produce the same error.


I can set the chart by doing "MSChart1.Row = row;" "MSChart1.Column =
col;" "MSChart1.Data = 3;". However, I have about a 200 points and
doing it this way takes the Chart about 20 seconds (it draws to the
chart after each point is set). I suspect the "MSChart1.ChartData =
myArr;" would be faster in this respect.

Another possbile solution, anyone know how to tell MSChart1 to not
draw while I set all the points (Then I can just do an
"MSChart1.Refresh();" when I'm done setting points.

Thanks

NB
 
N

NvrBst

I can't seem to set the "MSChart1.ChartData = myArr;" value using
JavaScript.  It says "Bad Argument".

I've tried setting myArr two ways.  1. var myArr = [1,2,3,4,5]; and 2.
var x = [1,2,3,4,5]; var myArr = [x];.  Both produce the same error.

I can set the chart by doing "MSChart1.Row = row;" "MSChart1.Column =
col;" "MSChart1.Data = 3;".  However, I have about a 200 points and
doing it this way takes the Chart about 20 seconds (it draws to the
chart after each point is set).  I suspect the "MSChart1.ChartData =
myArr;" would be faster in this respect.

Another possbile solution, anyone know how to tell MSChart1 to not
draw while I set all the points (Then I can just do an
"MSChart1.Refresh();" when I'm done setting points.

Thanks

NB

I found the "MSChart1.Redraw = bool" property. By wrapping my code in
that it cuts the inital loading from 20 seconds to about 9 seconds.
Updating is pretty instant but with a small flicker which isn't a
problem for me.

Thanks NB
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top