# Remove Pie Chart border

**URL:** <https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745>\
**Category:** Ignition\
**Created:** [January 25, 2013, 12:07pm UTC](https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745 "2013-01-25T12:07:56Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gnguyen](https://avatars.discourse-cdn.com/v4/letter/g/41988e/32.png) [@gnguyen](https://forum.inductiveautomation.com/u/gnguyen)\
**Post date:** [January 25, 2013, 12:07pm UTC](https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745/1 "2013-01-25T12:07:56Z")

</div>

Hello,

How can I remove the border of a pie chart ?  
 ![](https://us1.discourse-cdn.com/inductiveautomation/original/2X/c/cd2248a635bb1676fc9bd29c22b3ec8c3ac8ded1.png)

---

<div class="post-metadata">

**Author:** ![James.Lorenz](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/james.lorenz/32/3290_2.png) [@James.Lorenz](https://forum.inductiveautomation.com/u/James.Lorenz)\
**Post date:** [January 25, 2013, 6:56pm UTC](https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745/2 "2013-01-25T18:56:22Z")

</div>

You will need PiePlot#setOutlinePaint(), and use a RGB Java Color with an alpha value on the end. Setting the last value to 0 creates full transparency for the outline, regardless of color.

[code]from java.awt import Color

c = Color(128,128,128,0)  
event.source.parent.getComponent(“Pie Chart”).getChart().getPlot().setOutlinePaint©[/code]

---

<div class="post-metadata">

**Author:** ![brian.mcenulty](https://avatars.discourse-cdn.com/v4/letter/b/b77776/32.png) [@brian.mcenulty](https://forum.inductiveautomation.com/u/brian.mcenulty)\
**Post date:** [September 26, 2017, 11:38pm UTC](https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745/3 "2017-09-26T23:38:36Z")

</div>

I’m attempting to remove the border on a pie chart that is part of a template in another template. On the pie chart itself I have a propertyChange script configured with the following (as shown above).

```auto
 if event.propertyName == "componentRunning":
 	from java.awt import Color
 	c = Color(128,128,128,0)
 	event.source.parent.getComponent("Pie Chart").getChart().getPlot().setOutlinePaint(c)

```

This works if the pie chart is in a template instance, however if that template is then used in another template it no longer works and the border is visible. Is there any way around this?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [September 27, 2017, 12:29pm UTC](https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745/4 "2017-09-27T12:29:55Z")

</div>

Why are you using `parent.getComponent("Pie Chart")` ? Why not just `event.source.getChart()` … ?

---

<div class="post-metadata">

**Author:** ![brian.mcenulty](https://avatars.discourse-cdn.com/v4/letter/b/b77776/32.png) [@brian.mcenulty](https://forum.inductiveautomation.com/u/brian.mcenulty)\
**Post date:** [September 27, 2017, 3:10pm UTC](https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745/5 "2017-09-27T15:10:43Z")

</div>

Initially I tried this

```auto
chart = event.source.getChart()
plot = chart.getPlot()

plot.setOutlinePaint(c)

```

Either way the result was the same.

---

<div class="post-metadata">

**Author:** ![yzhang](https://avatars.discourse-cdn.com/v4/letter/y/87869e/32.png) [@yzhang](https://forum.inductiveautomation.com/u/yzhang)\
**Post date:** [March 16, 2021, 8:51pm UTC](https://forum.inductiveautomation.com/t/remove-pie-chart-border/5745/6 "2021-03-16T20:51:05Z")

</div>

I am still having this problem, and the script is not working, any ideas?

I am kind of surprised that after so many years, I still have this problem.

I am working with 8.1.3
