PopUpMenu auto change

HI Everyone
I use 4 popupmenu ( with numbers 1 to 4 in initValue) To select the sequence of the task to trigger
Is there a easy way to force any of 4 popupmenu to never display the same number of other popupmenu
EX.: If i select the number 3 on Popupmenu1, id like to force the Popupmenu3 (who have init number 3) to change for the only number available
Hoping my explanation’s clear

There is no way for one popupmenu to “know” what to display when another is changed. So, there is no automatic way.

Since the display appears to follow a logic, and I must admit I am not entirely clear what that is, you could manage that logic in a method that is called by the selectionchanged event of any given popupmenu, in order to perform the “automatic” selections.

I have something similar in one of my apps. When the first popupmenu selection is changed, a method is called. It selects data from a database using the selection of the first popupmenu as a parameter, and fills a second popupmenu. The second popupmenu becomes active after the selection method is completed.

hope this helps.

There is no need to disable the second (third, fourth, …) popup, just change the values in the Change event of every popupmenu accordly to what’s selected.

Technically, you are correct. However, you may want the selections to occur sequentially, rather than in any random order. My approach is in such cases, to make the “correct” control active or visible, and to make further selections active or visible as appropriate.

Granted, not all processes need to go to such extremes. There are many cases where this is not at all necessary. However, when control #2 content depends on control #1 selection and control #3 content depends on control #2 selection, then it is safer to proceed in managed steps.

my way to approach the problem is to change the index to display the right number of the other popupmenu according the current number
But im just hoping to skip the complexity of managing all possibility
EX.: if i change the third menu then change the first after. I have to check the index of all menu then find the number available.
Not very complex. I just wondering if by duplicating the first menu, if there somehow link together by index then behave like i want.
After try it. i know it doesnt work