# "Best Practices" question related to Popup Menu and Page Panels

**URL:** <https://forum.xojo.com/t/best-practices-question-related-to-popup-menu-and-page-panels/11206>\
**Category:** Getting Started\
**Created:** [September 25, 2013, 7:14pm UTC](https://forum.xojo.com/t/best-practices-question-related-to-popup-menu-and-page-panels/11206 "2013-09-25T19:14:01Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![LiamP](https://forum.xojo.com/user_avatar/forum.xojo.com/liamp/32/543_2.png) [@LiamP](https://forum.xojo.com/u/LiamP)\
**Post date:** [September 25, 2013, 7:14pm UTC](https://forum.xojo.com/t/best-practices-question-related-to-popup-menu-and-page-panels/11206/1 "2013-09-25T19:14:01Z")

</div>

Having recently done quite a bit of work in FileMaker, I have a question about how best to show the user a fairly large but not enormous number of options for selecting the data to go into a field. Specifically, I am working on an American History project where I need to associate an Native American’s individual record with the particular Tribe AND Subtribe they are a member of. Example would be Lakota Tribe and Oglala Subtribe. I have a Tribe table with all (most) Native American Tribes and an additional table with the Subtribes.

I have a foreign key field in the individual’s record to link to the tribe and I have considered 2 alternative ways of presenting these to the user. The first would be to use Page Panels and just have a listbox populated with all of the rows from the Tribe table on a page that is shown when they click the select button. The second would be to populate the values of a Popup Menu with the Tribes.

What would be the most efficient/preferred method to do this? I mentioned FileMaker because it is very easy to populate a value list from all the rows in a table to present the user.

Thanks in advance,  
Bill

---

<div class="post-metadata">

**Author:** ![Peter\_Fargo](https://forum.xojo.com/user_avatar/forum.xojo.com/peter_fargo/32/977_2.png) [@Peter\_Fargo](https://forum.xojo.com/u/Peter_Fargo)\
**Post date:** [September 26, 2013, 11:01am UTC](https://forum.xojo.com/t/best-practices-question-related-to-popup-menu-and-page-panels/11206/2 "2013-09-26T11:01:02Z")

</div>

The preferred way is what works for your UI. Another option would be to have the user select the Tribe and have a dynamic list of radio buttons to select the Subtribe. You can do that pretty easily using a control set. Here is some code I use to load a list of servers in a restaurant pos system. There is a groupbox with a single radiobutton “rbServer” set up as a control set. I have an array of server names which is built using a query when the app launches. It is a multicolumn list so there is some extra calculating going on for that. In your case you would delete the exisiting list and repopulate based on your subtribe query.

[code] Dim i, count , iTop, iLeft, reset, colCount As Integer

Dim rb As RadioButton

reset = 15 ’ number of servers per column

count = ServerNames.Ubound  
iTop = rbServer(0).Top  
iLeft = rbServer(0).Left

rbServer(0).Caption = ServerNames(0)

For i = 1 to count

```
colCount = colCount + 1

iTop = iTop + rbServer(0).Height + 10

If colCount mod 14 = 0 then
  iLeft = iLeft + rbServer(0).Width + 10
  iTop = rbServer(0).Top
End if

rb = New rbServer

rb.top = iTop
rb.Left = iLeft
rb.Caption = ServerNames(i)

```

Next[/code]

---

<div class="post-metadata">

**Author:** ![LiamP](https://forum.xojo.com/user_avatar/forum.xojo.com/liamp/32/543_2.png) [@LiamP](https://forum.xojo.com/u/LiamP)\
**Post date:** [September 27, 2013, 7:29pm UTC](https://forum.xojo.com/t/best-practices-question-related-to-popup-menu-and-page-panels/11206/3 "2013-09-27T19:29:46Z")

</div>

Thank you Peter, that would work quite well since the number sub-tribes associated with each tribe would be pretty small.

thanks again

---

<div class="post-metadata">

**Author:** ![system](https://forum.xojo.com/uploads/default/original/1X/455b4dcc0e61630e9f81940004ddffa49c432a46.png) [@system](https://forum.xojo.com/u/system)\
**Post date:** [October 29, 2020, 4:52pm UTC](https://forum.xojo.com/t/best-practices-question-related-to-popup-menu-and-page-panels/11206/4 "2020-10-29T16:52:05Z")

</div>


