You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Asdrubael <gr...@hotmail.com> on 2011/05/27 12:12:18 UTC
ChenilleKit Tapestry - updating a chart
Hello,
I want to add a chart on my page, with ChenilleKit. Like in this page :
http://www.chenillekit.org/chenillekit-tapestry/ref/org/chenillekit/tapestry/core/components/Chart.html
http://www.chenillekit.org/chenillekit-tapestry/ref/org/chenillekit/tapestry/core/components/Chart.html
It works, but now, I want to make this chart dynamic and update the values
displayed on the chart. I tried to place the chart in a t:zone, in order to
refresh it with some js code.
My tml file :
<t:zone t:id="zone" t:update="show">
<div t:id="chart" style="width:350px;height:150px;"/>
</t:zone>
#
My js file :
var timerId;
var linkId='refreshZone';
function updateMyZone() {
var actionLink = $(linkId);
Tapestry.findZoneManager(actionLink).updateFromURL(actionLink.href);
}
function startTimer() {
timerId = window.setInterval('updateMyZone()',1000);
}
function stopTimer() {
clearInterval(timerId);
}
refresh = function(){
startTimer();
};
The fact is that this code works for updating others stuffs, but with a
ChenilleKit chart, I have an error :
"Client exception processing response: SyntaxError: missing ; before
statement"
I'm sure that the problem comes from the js, but I don't see where ? Can
everyone give me a hint ?
--
View this message in context: http://tapestry.1045711.n5.nabble.com/ChenilleKit-Tapestry-updating-a-chart-tp4431417p4431417.html
Sent from the Tapestry - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org