Using IWChartJS - 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: Using IWChartJS (/thread-2802.html) |
Using IWChartJS - Alexandre Machado - 07-19-2022 Hi guys, a new demo showing how to use the new IWChartJS component with IntraWeb. Super easy to create amazing charts. Check it out: https://github.com/Atozed/IntraWeb/tree/master/15/Delphi/ChartJS [attachment=512] RE: Using IWChartJS - PaulWeem - 07-20-2022 Hi Alexandre, Thank you very much for this demo, very helpful. Just one question: How do I combine a Bar and and a Line in one chart? Thanks in advance! Cheers, Paul RE: Using IWChartJS - Alexandre Machado - 07-21-2022 Hi Paul, I'm glad that you liked the demo. This is a missing bit that it's ready but I couldn't test before releasing the latest update (15.2.64) so it hasn't been included, but we are going to release it in a few days. To combine 2 different charts in one, you just need to create a second series with a different chart type. If you check the third chart in that demo, I create 1 additional series (the main series is built-in). For instance, to change the second series to a line, you can do this: // create a second series here SecondSeries := IWChartJS4.AddSeries(ctLine, 'Year 2050'); Then you will have the main series as a bar chart and the second series as a line one. Simple :-) RE: Using IWChartJS - PaulWeem - 07-21-2022 Hi Alexandre, Thank you for your response. I tried creating a second series as a ctLine, and I can confirm that this doesn't work. Whatever I try, the Chart keeps showing all series as the ChartType initially set on the TIWChartJS itself. Cheers, Paul RE: Using IWChartJS - Lorbass - 07-27-2022 (07-21-2022, 07:59 AM)PaulWeem Wrote: Hi Alexandre, Great that now Charts are implemented! But I can confirm what Paul says. In addition, the legend display does not work correctly for all ChartTypes: ctPie works correct, ctBar does not. Another question: Is it possible to generate stack bars? Cheers, Detlef RE: Using IWChartJS - Alexandre Machado - 07-29-2022 what do you mean the legend display do not work correctly for ctBar? The example below is from the demo application. Seems to work correctly for me [attachment=515] RE: Using IWChartJS - Alexandre Machado - 07-29-2022 Regarding stack bars, yes, it will be possible in the next release |