How can I get Menu Click event?

rrhirani
Participant IV

I need to display options in Dropdown dynamically, Here I have 2 menus means 2 views.

If Dashboard menu A is clicked then value 1,2,3 will show in the form dropdown and if the user clicks on menu B then the value should be 4,5 and 6.
Same table and same column(Enumlist)

I need a clicked View value e.g. if the user clicks on View A then I need that value โ€œAโ€.

Any suggestions would be great. Thanks

Solved Solved
0 3 426
1 ACCEPTED SOLUTION

Hi @rrhirani,

I presume by menu you mean views. Also based on your description you have the two views A and B on the same table and you are using forms to select those drop downs.

If so, please explore if following approach helps you.

If A_Form is the form view corresponding to the Vietw A and B_Form is the view corresponding to the View B , then in the dropdown fieldโ€™s valid_if you may have an expression something like

IFS(CONTEXT(โ€œViewโ€)=โ€œA_Formโ€,{1,2,3},CONTEXT(โ€œViewโ€)=โ€œB_Formโ€,{4,5,6})

The approach mentioned above uses CONTEXT() expressions. You may wish to refer to following article on CONTEXT() function just in case you have not

View solution in original post

3 REPLIES 3

Hi @rrhirani,

I presume by menu you mean views. Also based on your description you have the two views A and B on the same table and you are using forms to select those drop downs.

If so, please explore if following approach helps you.

If A_Form is the form view corresponding to the Vietw A and B_Form is the view corresponding to the View B , then in the dropdown fieldโ€™s valid_if you may have an expression something like

IFS(CONTEXT(โ€œViewโ€)=โ€œA_Formโ€,{1,2,3},CONTEXT(โ€œViewโ€)=โ€œB_Formโ€,{4,5,6})

The approach mentioned above uses CONTEXT() expressions. You may wish to refer to following article on CONTEXT() function just in case you have not

@Suvrutt_Gurjar : First of all, many thanks for your perfect solution. itโ€™s working like a charm!!
and Yes, I meant menu means View. Iโ€™ve edited my question so nobody gets confused. Thanks a lot for giving me CONTEXT() function idea

Hi @rrhirani,
Thank you for your update. Good to know the approach works for you.

Top Labels in this Space