<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"><channel><category>pcsoft.us.windev</category><copyright>Copyright 2026, PC SOFT</copyright><lastBuildDate>23 Jan 2016 15:37:00 Z</lastBuildDate><pubDate>18 Jan 2016 10:01:00 Z</pubDate><description>Hi,&#13;
&#13;
I have some trouble with charts. I do not want to bind anything to the chart control . This is because I want to fill it by programming.&#13;
&#13;
Ok the basic stuff goes fine when I want to generate a bar chart. I do have some problems with the placement of the leggent and I havenot added the colour of the specific bars but the rest seems to work as expected.&#13;
&#13;
I want to be able to change the type of chart by programming. So user can slecet if he wants a bar chart or a pie chart. This doesnot work. The bar chart can handle the grAdd Data() but the pie charts only load one loop.&#13;
&#13;
I looked at the example but there the graph is linked to a querie in the control. I cannot use that.&#13;
&#13;
My code:&#13;
&#13;
cyTotaalbedrag is currency&#13;
nTeller is int = 0&#13;
&#13;
grDeleteSeries(CHART_NoName1)&#13;
grCreate(CHART_NoName1,grColumn) // this is for the barchart&#13;
grTitle(CHART_NoName1,"",grNone)&#13;
FOR ALL Dashboard_widget_instelregels WHERE Dashboard_widget_instellingenID = gnDashboardinstID&#13;
&#13;
nTeller = nTeller+1&#13;
cyTotaalbedrag = 0&#13;
// QRY_voorsunburstOmzet_per_klant.ParamBeginDatum&#13;
// QRY_voorsunburstOmzet_per_klant.ParamEindDatum&#13;
// QRY_voorsunburstOmzet_per_klant.ParamGrootboekID&#13;
// QRY_voorsunburstOmzet_per_klant.ParamklantenID&#13;
IF Dashboard_widget_instelregels.Nivo3 &lt;&gt; 0 THEN&#13;
QRY_voorsunburstOmzet_per_klant.ParamBalansNivo2 = Dashboard_widget_instelregels.Nivo3&#13;
END&#13;
QRY_voorsunburstOmzet_per_klant.ParamBalansNivo1 = Dashboard_widget_instelregels.Nivo2&#13;
HExecuteQuery(QRY_voorsunburstOmzet_per_klant,hQueryDefault)&#13;
&#13;
FOR ALL QRY_voorsunburstOmzet_per_klant&#13;
cyTotaalbedrag += QRY_voorsunburstOmzet_per_klant.Saldo&#13;
END&#13;
IF HReadSeekFirst(Dashboard_widget_instellingen,Dashboard_widget_instellingenID,gnDashboardinstID) THEN&#13;
IF Dashboard_widget_instellingen.Labelsopnemen = 1 THEN&#13;
grSeriesLabel(CHART_NoName1,nTeller,Dashboard_widget_instelregels.Reeks)&#13;
END&#13;
END&#13;
grAddData(CHART_NoName1,nTeller,cyTotaalbedrag)&#13;
&#13;
END&#13;
IF HReadSeekFirst(Dashboard_widget_instellingen,Dashboard_widget_instellingenID,gnDashboardinstID) THEN&#13;
IF Dashboard_widget_instellingen.omschrijvingXAs &lt;&gt;"" THEN&#13;
grAxisTitle(CHART_NoName1,Dashboard_widget_instellingen.omschrijvingXAs,grXCoordinate)&#13;
END&#13;
IF Dashboard_widget_instellingen.omschrijvingYas &lt;&gt;"" THEN&#13;
grAxisTitle(CHART_NoName1,Dashboard_widget_instellingen.omschrijvingYas,grYCoordinate)&#13;
END&#13;
&#13;
IF Dashboard_widget_instellingen.RasterXas = 1 THEN&#13;
grGridLines(CHART_NoName1,True,grXCoordinate)&#13;
ELSE&#13;
grGridLines(CHART_NoName1,False,grXCoordinate)&#13;
END&#13;
IF Dashboard_widget_instellingen.RasterYas = 1 THEN&#13;
grGridLines(CHART_NoName1,True,grYCoordinate)&#13;
ELSE&#13;
grGridLines(CHART_NoName1,False,grYCoordinate)&#13;
END&#13;
&#13;
&#13;
END&#13;
IF Dashboard_widget_instellingen.LegendaOpnemen = True THEN&#13;
SWITCH Dashboard_widget_instellingen.Legendaoptie&#13;
CASE 1&#13;
grLegend(CHART_NoName1,grAtBottom)&#13;
CASE 2&#13;
grLegend(CHART_NoName1,grAtTop)&#13;
CASE 3&#13;
grLegend(CHART_NoName1,grAtLeft)&#13;
CASE 4&#13;
grLegend(CHART_NoName1,grAtRight)&#13;
OTHER CASE&#13;
grLegend(CHART_NoName1,grNone)&#13;
&#13;
END&#13;
ELSE&#13;
grLegend(CHART_NoName1,grNone)&#13;
END&#13;
&#13;
grDraw(CHART_NoName1)&#13;
&#13;
&#13;
&#13;
Anyone an Idea why this works wth bar chart and not with pie charts. ??&#13;
&#13;
regards&#13;
&#13;
Allard</description><ttl>30</ttl><generator>WEBDEV</generator><language>en_US</language><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming/read.awp</link><title>charts by programming</title><managingEditor>moderateur@pcsoft.fr (El moderador)</managingEditor><webMaster>webmaster@pcsoft.fr (El webmaster)</webMaster><item><author>guest</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-56014/read.awp</comments><pubDate>23 Jan 2016 15:37:00 Z</pubDate><description>Hi you all&#13;
&#13;
I ran into an odd problem whebn dynamicly adding the ledgent to a cart.&#13;
&#13;
Important if you do dynamicly creating …</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-56014/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-56014/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming/read.awp">charts by programming</source><title>Re: charts by programming</title></item><item><author>guest</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-55919/read.awp</comments><pubDate>19 Jan 2016 01:53:00 Z</pubDate><description>Thanks for getting back to us on the answer Allard, appreciate it. We all benefit when a good solution is posted. :spos:</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-55919/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-55919/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming/read.awp">charts by programming</source><title>Re: charts by programming</title></item><item><author>guest</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-55918/read.awp</comments><pubDate>19 Jan 2016 01:16:00 Z</pubDate><description>Hi you all,&#13;
&#13;
since quite a view of you all viewed this topic I guess I should post you my answer.&#13;
The simple mistake that I m…</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-55918/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming-55918/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55899-charts-programming/read.awp">charts by programming</source><title>Re: charts by programming</title></item></channel></rss>
