Skip to main content

Hello Lucid community!


I would like to somehow create a scenario where if two of my layers are hidden at the same time this would cause all other layers to be hidden.


For example in the image below the box's labelled UPS7 and UPS8 act as the power supply for the boxes labelled STS1 STS2 and STS3.


I want to create the scenario where all green lines will be hidden (i.e. all power is cut) when both UPS 7 and UPS 8 are turned off at the same time.  
If one of UPS7 or UPS8 are turned off the power (the green lines) will remain. 


Let me know if you know of a solution!


Hi Sam 


Thanks for posting in the Lucidchart Community! The best way to achieve the effect you're looking for would be by adding action to a shape to turn it into a button to toggle/hide/show your layers. I will use your example to outline the steps: 



  1. First create an object to function as your toggle/hide/show button. In the example below I created an object and added the descriptive label text "Power Cut Button."

  2. Make sure you have a separate layer(s) specific to the objects you want to toggle/hide/show. In the example below I created two layers: USP and Power Green Lines. 

  3. Make sure the objects you want to toggle/hie/show are assigned to those layers. In the example below I assigned the shapes UPS 7 and UPS 8 to the layer "UPS" and the lines connecting the UPS shapes and the STS shapes to the layer "Power Green Lines."  

  4. Select the object you worked to function as a toggle on/off button > Click on the lightning bolt icon in the formatting bar.

  5. Select Layers > Select the type of action you'd like to add to your shape > Check the boxes next to the layer(s) you'd like to be toggled/hidden/shown by the button. 

  6. Click Done.




Now every time I activate my "Power Cut Button" it toggles on/off the "UPS" and "Power Green Lines" layers. See what it looks like when I activate the button to toggle the layers off: 


You can use this process to create one layer for each UPS shape > assign each of those UPS shapes to their respective layers > create a button that will toggle/hide/show only one of the UPS shapes without affecting the green lines. 

Please note that in order to activate a shape with an action you must hold down Shift+Ctrl (Shift+Cmd for Mac). 


I hope this helps! For more information about how to use actions to toggle/hide/show layers please review our Add Actions to a diagram and Add Layers to a Diagram articles from the Lucidchart Help Center. 


Reply