Referencing Cells with a Slider or Pop-Up (Numbers)

I'm constructing a sheet containing multiple tables. As it stands, I populate the data in the header column of the small PMZ TETRA 1 (HORIZ ROT) table (inside the blue box) from the header column of the larger PMZ TETRA 1 PERMUTATIONS table above it.

What I would like to be able to do, however, is dynamically choose which PERMUTATIONS column (1–24; actually 2–25, of course) to reference, so that I can easily switch between possible results in the smaller tables below. I'd like to be able to use a pop-up menu to reference the table column 1–24 from which the four rows' values would be returned in the other table(s).


Is this possible?

Posted on Nov 6, 2023 1:34 PM

Reply
Question marked as ⚠️ Top-ranking reply

Posted on Nov 6, 2023 3:34 PM

In cell A3

=XLOOKUP(E$1,PMZ TETRA 1 PERMUTATIONS::B$2:Y$2,PMZ TETRA 1 PERMUTATIONS::B3:Y3,0)


The copy down until A6.



You see that I put the drop-down menu in cell E1 of the table, which means that you'll have to unmerge the cells of row 1 and only merge the first four ones.

7 replies
Sort By: 
Question marked as ⚠️ Top-ranking reply

Nov 6, 2023 3:34 PM in response to judddanby

In cell A3

=XLOOKUP(E$1,PMZ TETRA 1 PERMUTATIONS::B$2:Y$2,PMZ TETRA 1 PERMUTATIONS::B3:Y3,0)


The copy down until A6.



You see that I put the drop-down menu in cell E1 of the table, which means that you'll have to unmerge the cells of row 1 and only merge the first four ones.

Reply

Nov 6, 2023 1:48 PM in response to judddanby

Where would that pop-up menu be located? (in which cells?)

What would be its values?

From that selection, how are the small tables getting their data, in other words, how does it relate to the permutation number?

This picture has to be a montage, you cannot have four tables with the same name on the same sheet.

Reply

Nov 6, 2023 2:06 PM in response to Recycleur

No montage. They have longer names that are visually truncated.


The small table currently get their header-column data from the header-column data (hand-entered) in the large table above.


I could put the pop-up in a new header column in the small tables.


I hope that clarifies things.

Reply

Nov 6, 2023 2:21 PM in response to judddanby

Do you mean that the pup-ups would replace the 1-2-3-4 at the top of each column in the small tables? Or the 3-7-8-10 in the first column? Or neither? One for each? So you could select 1 to 24 for each one?


Otherwise, it's not clear where, for example, the 10 at the intersection of 8 and 1 in the first small table comes from. That's important because it determines how the number in the pop-up would be used (if you're looking for a formula to populate the small tables).


In other words, explain it that way: the formula in cell W (what address?) will use the number in pop-up cell X (what address?) to look for a number in range Y (what address?) of the big table and return another number from range Z (what address?) of the big table.

Reply

Nov 6, 2023 5:04 PM in response to Recycleur

Fantastic, thanks!


I had gotten caught up wondering if there was a way to include a variable in a cell reference (basically, table::($)[var]($)#) and didn't think about reference functions like (X)LOOKUP. Again, many thanks, Recycleur! I appreciate your time and assistance.

Reply

Nov 6, 2023 6:38 PM in response to judddanby

You're welcome.


So you wanted something complicated. Like that? LOL!

=INDIRECT(ADDRESS(ROW(),$E$1+1,4,TRUE,"PMZ TETRA 1 PERMUTATIONS"))


Quite unsafe though as it relies on the fact that both tables always have the same structure (unless you want to rewrite the formula) and that the main table never changes name (because it's hard-coded as a string). XLOOKUP better.

Reply

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Referencing Cells with a Slider or Pop-Up (Numbers)

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.