22
Views
7
Comments
[OutSystems UI] Submenu is opening fine but when try to collapse/close the submenu - its not closing
outsystems-ui
Reactive icon
Forge asset by OutSystems

I have Submenu in My  app and when click on submenu header its opening fine but when try to close/collapse the submenu : its not closing again..
tried diff diff solution but not getting any access. 

below is our action diagram.
any help will be appreciated... and please check the attachments as well
NOTE : this is a single page application.




Screenshot 2025-06-23 at 7.49.15 PM.png
Screenshot 2025-06-24 at 12.34.38 PM.png
2026-01-28 16-57-48
Mihai Melencu
Champion

Hi @Dharmesh Rathore ,

I assume you're using the OnToggle event handler of the sub-menu, but keep in mind that this event is meant for triggering custom logic, not for controlling the sub-menu's open/close behavior. The sub-menu should open or close automatically when its title is clicked, without requiring any additional logic. 

So, if you don’t need any custom logic, I recommend removing the event handler.

UserImage.jpg
Dharmesh Rathore

Hi @Mihai Melencu
Thanks for your reply.
Yes I added toggle event behaviour because when I click submenu item then whole submenu was  closing automatically which is not correct.
Behaviour should be if I click any item of any Submenu then that submenu should be open and should be closed only when its title is clicked. So by using that toggle event handler I achieved that but now when its title is clicked its Submenu is opening fine but clicking again submenu is not closing.

2025-07-28 06-45-20
Rupesh Patil

Hi @Dharmesh Rathore 

You can check this link:

https://personal-roecb4u9.outsystemscloud.com/RWA_Lab/NeoLike

I have attached oml file below.

I hope this helps

Thanks

SubMenu.oml
UserImage.jpg
Dharmesh Rathore

Hi @Rupesh Patil
Thanks for your reply.
I have seen that but in our app we are using single page application so its not working for me.

2025-07-28 06-45-20
Rupesh Patil
2025-07-22 10-30-27
Mandar Deshpande

Hi @Dharmesh Rathore It looks like you are not toggling the variable before entering the If. So, the flow always executes the same branch(open).

2022-11-12 11-28-30
Gonçalo Martins
Staff

Hello @Dharmesh Rathore 

Any update about this reported issue?

Cheers,
GM

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.