# Fill paint with button clicked

**URL:** <https://forum.inductiveautomation.com/t/fill-paint-with-button-clicked/72435>\
**Category:** Ignition\
**Tags:** ignition79\
**Created:** [April 13, 2023, 8:01pm UTC](https://forum.inductiveautomation.com/t/fill-paint-with-button-clicked/72435 "2023-04-13T20:01:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jamshidzade](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jamshidzade/32/24927_2.png) [@jamshidzade](https://forum.inductiveautomation.com/u/jamshidzade)\
**Post date:** [April 13, 2023, 8:01pm UTC](https://forum.inductiveautomation.com/t/fill-paint-with-button-clicked/72435/1 "2023-04-13T20:01:05Z")

</div>

I have difficulty designing a button when clicking to change the symbol color to different color

this code on event handler action performed event.source.parent.getComponent('Circle').fillPaint = '#FFFFFF'

but it is not working

 ![latch watch](https://us1.discourse-cdn.com/inductiveautomation/original/3X/c/e/cef96b9b0db59894412279a470b3ed06722ccb00.jpeg)

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [April 13, 2023, 8:09pm UTC](https://forum.inductiveautomation.com/t/fill-paint-with-button-clicked/72435/2 "2023-04-13T20:09:45Z")

</div>

Vision components need Java Color objects, not strings.  
Try `event.source.parent.getComponent("Circle").fillPaint = system.gui.color(255, 255, 255)`.

---

<div class="post-metadata">

**Author:** ![jamshidzade](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jamshidzade/32/24927_2.png) [@jamshidzade](https://forum.inductiveautomation.com/u/jamshidzade)\
**Post date:** [April 13, 2023, 8:10pm UTC](https://forum.inductiveautomation.com/t/fill-paint-with-button-clicked/72435/3 "2023-04-13T20:10:35Z")

</div>

You are the best
