# Component Context Menu - Disable menu items?

**URL:** <https://forum.inductiveautomation.com/t/component-context-menu-disable-menu-items/90567>\
**Category:** Ignition\
**Created:** [May 17, 2024, 4:42pm UTC](https://forum.inductiveautomation.com/t/component-context-menu-disable-menu-items/90567 "2024-05-17T16:42:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eric\_Gruber](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/eric_gruber/32/51070_2.png) [@Eric\_Gruber](https://forum.inductiveautomation.com/u/Eric_Gruber)\
**Post date:** [May 17, 2024, 4:42pm UTC](https://forum.inductiveautomation.com/t/component-context-menu-disable-menu-items/90567/1 "2024-05-17T16:42:49Z")

</div>

I have been making use of the context menu to send message handlers where a function is performed. Under certain circumstances, the function shall not be carried out. To achieve that I have written a conditional statement that if the function was not allowed, an information popup is displayed to the user.

I would rather disable the menu item (not the entire context menu) but I don't know if and how this can be done. Is it possible?

Perspective in version 8.1.34

---

<div class="post-metadata">

**Author:** ![Ryan\_Deardorff](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan_deardorff/32/63815_2.png) [@Ryan\_Deardorff](https://forum.inductiveautomation.com/u/Ryan_Deardorff)\
**Post date:** [May 17, 2024, 5:10pm UTC](https://forum.inductiveautomation.com/t/component-context-menu-disable-menu-items/90567/2 "2024-05-17T17:10:03Z")

</div>

I have handled this by generating the menu items with a script, and simply not including the items that shouldn't be enabled.

But you could probably use the "style" element to make the item _look_ disabled and then do nothing when its message is sent.
