Internet problem: reset canvas

Share RGraph:   To help my Google visibility (it can't get much worse!), if you like and use RGraph I'd appreciate it if you could link to me

« Back to message list

Enter your email address to get email updates on this topic. You can stop receiving updates by clicking the link in the update email messages.

Posted by jlost55 on 23rd April 2014
Hi there,

I can reset my canvas in Google Chrome, Firefox, Opera and Safari with RGraph.Reset(canvas). In Internet Explorer, it doesn't work.

Is there a solution for Internet Explorer?
Posted by Richard on 23rd April 2014
Hi there,

You could try resetting it manually by setting the width to itself:

var canvas = document.getElementById('cvs');

canvas.width = canvas.width






Richard
www.rgraph.net
If RGraph has helped you - please share the website - thanks!

RGraph Priority Support: www.rgraph.net/support#priority-support
Posted by jlost55 on 23rd April 2014
That was my previous solution. It give the same problem like RGraph.reset(canvas).
Posted by Richard on 23rd April 2014
Hi there,

The RGraph.reset function works in Internet Explorer - as this example shows:

www.rgraph.net/fiddle/view/a-line-chart-with-clipping2




Richard
www.rgraph.net
If RGraph has helped you - please share the website - thanks!

RGraph Priority Support: www.rgraph.net/support#priority-support
Posted by jlost55 on 24th April 2014
The problem that I have is it between the static canvas and the dynamic canvas in Internet Explorer. The dynamic canvas wouldn't reset.
Posted by Richard on 24th April 2014
Hi there,

Which version? If 8 then dynamic features aren't available in IE8. If higher it should reset - but you could always delete from the DOM and readd a new canvas in its place.




Richard
www.rgraph.net
If RGraph has helped you - please share the website - thanks!

RGraph Priority Support: www.rgraph.net/support#priority-support
Posted by jlost55 on 25th April 2014
Hi there,

What is DOM?

I have problems with all versions of Internet Explorer (version 9, 10 and 11).

I created a video when you can see my problem.

This is my website on Internet Explorer (problem)
www.dropbox.com/s/8k5haz6dehc53ul/Internet%20Explorer.avi

This is my website on Google Chrome (it works also on Safari for Windows, Mozilla Firefox and Opera)
www.dropbox.com/s/zhbsoh1fdqfo5xo/Google%20Chrome.avi
Posted by Richard on 25th April 2014
Hi there,

It appears as though the canvas isn't being cleared/redrawn so the crosshairs are being drawn again and again over the same chart.

The fact that you said 9/10/11 would suggest that you might be using an emulator - don't - I've found them to be quite unreliable where canvas is concerned.

If you want to provide a demo - upload that to dropbox along with all the libraries and send the URL to that.






Richard
www.rgraph.net
If RGraph has helped you - please share the website - thanks!

RGraph Priority Support: www.rgraph.net/support#priority-support
Posted by jlost55 on 25th April 2014
Hi there,

I tested my website on a real computer and not an emulator.

I created a demo webpage with JSFiddle. You can see my problem on Internet Explorer. In Google Chrome it works.

URL: jsfiddle.net/jlost55/8DLZp/
Posted by Richard on 25th April 2014
Hi there,

1. Why on earth are you drawing the crosshairs yourself? Simply include the dynamic library and use the crosshairs option.

www.rgraph.net/docs/line.html

2. If you use the Line chart there will be no X value - for that you will need a Scatter chart with a connecting line - an XY chart essentially.

www.rgraph.net/docs/scatter.html



Richard
www.rgraph.net
If RGraph has helped you - please share the website - thanks!

RGraph Priority Support: www.rgraph.net/support#priority-support
Posted by jlost55 on 25th April 2014
Hi there,

I use now the dynamic library and the crosshairs option. It works. My problems works now for Internet Explorer and the other browsers.

Thanks!

Add a reply




« Back to message list