![]() |
Change Javascript Chart - Printable Version +- Atozed Forums (https://www.atozed.com/forums) +-- Forum: Atozed Software Products (https://www.atozed.com/forums/forum-1.html) +--- Forum: IntraWeb (https://www.atozed.com/forums/forum-3.html) +---- Forum: English (https://www.atozed.com/forums/forum-16.html) +----- Forum: IntraWeb General Discussion (https://www.atozed.com/forums/forum-4.html) +----- Thread: Change Javascript Chart (/thread-2476.html) |
Change Javascript Chart - matija - 08-05-2021 I use chartjs.org in my HTML template with variables <script> var cType="bar"; var xValues=["Item1","Item2","Item3"]; var yValues=[34,12,45]; .... </script> I will with IWButton click change this variables and draw chart? I tried with WebApplication.CallBackResponse.AddJavaScriptToExecuteAsCDATA('var cType = "line";'); and not work! Maybe is any variant this implementation with RegisterCallBack for change my variables? RE: Change Javascript Chart - Jose Nilton Pace - 08-05-2021 Try update your chart. Code: WebApplication.CallBackResponse.AddJavaScriptToExecuteAsCDATA('var cType = "line"; yourchart.update();'); |