Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Display of Value List's Second Field in Dropdown box

Featured Replies

  • Newbies

I have an Value List wherein ID is first field (do not display) and 2nd field is Name. The ID is a one to many relationship. In Forms, the related field stores the ID, but I want the Name to display. If I choose to display data from the Value List as a Popup Menu, it displays the Name correctly. If, however, I display as a Dropdown box, it displays the ID (1st field) instead of the Name. (It wouldn't be so bad if I didn't hate the popup menu -- it gets in the way when I'm tabbing through a record.)

I was informed by a veteran programmer that this is an irritating "bug". Has this been fixed in Filemaker 10? It does not display correctly when I mask the dropdown box with a textbox when I publish to the Intranet.

This isn't a bug, this is the behavior of drop-down lists.

  • Author
  • Newbies

If this is the expected behavior, how do I use a mask and get the proper value (second value) to show when publishing to the Intranet?

Has the behavior of the dropdown box changed in Version 10?

No, drop downs haven't changed in FM10. I don't know how to use a mask for IWP purposes.

  • Author
  • Newbies

Thanks. I don't understand why there is an option to display the second field, if it doesn't work with the drop down box.

I searched the Forum. I know I am not the only one who has invested time and frustration into making something work that simply is not possible when selecting the options as offered.

Use the pop-up menu instead of drop-down list.

The ddl gives the user the option of entering something that isn't in the list of displayed values. In this situation (entering IDs but displaying second field) allowing the entry of other values would not be appropriate, the pop-up menu is a better interface choice.

  • Author
  • Newbies

Tried the popup box. It gets in the way when tabbing through a record.

You're right, we get this question a lot. When you say that a popup menu "gets in the way," it suggests that it's quite long. You may consider a popup window with a list view for the user to select from.

I have the same sort of setup as airr. I currently use a pop-up list, but as it has around 200 records in it, it is quite slow to scroll.

As described here, a drop down list would be great but is not going to work. Is there any way of expanding the pop-up list horizontally? I've done some searches and it doesn't seem like it.

No, you cannot expand horizontally. As I suggested above, you need a button "Select" and a new window with a list of choices.

I like to include a filter. This filter can filter a portal AND/OR be used to filter a second pop-up (see yellow in sample file).

Anything can be used to 'break up' a large value list ... Type, Category, Country etc (known as conditional value list). In the sample file, I don't have enough of each alpha but you get my drift, I hope. :wink2:

FilteredPopup.zip

Edited by Guest

LaRetta beat me to the demo. Here's one using a List View popup. One more thing to add, would be to allow people to Find while still in the popup.

PopupSelectDemo.fp7.zip

How about removing the field with the pop-up from the TAB order?

I don't understand why there is an option to display the second field, if it doesn't work with the drop down box....frustration into making something work that simply is not possible when selecting the options as offered.

It does exactly as it says it will do ... DISPLAY the name in the drop-down. It does not say it will still display the name after selection. If you read FM Help on both drop-down and pop-up, they provide different interface purposes.

I DO agree that it would be nice if, after selection, a drop-down still displayed the name. But that doesn't mean the behavior goes against FM Help (at least not in THIS instance). :wink2:

Edited by Guest

Thank you for uploading some samples. I am currently playing with the "open a separate" list idea. Just trying to customise it to work with my db.

Cheers

bcooney,

I have tried to implement your solution as I believe it would suit my needs well. I've copied your scripts but it does not work. I believe it might be because my fields aren't assigned correctly in your script.

If you could be so kind to have a look at my attached database that would be great. I am trying to use this script to assign crew to the selected sector.

Thank you

Edited by Guest
file redacted at users request...

You're creating a new flight record, but you should be creating a new Assignment record. You'll need a SectorID and a CrewID. You get the CrewID from the select popup. Your SectorID is in gSelectedSector.

zSelectedSector should be a global field. The relationship to Assignments should be from Flights to Assignments by FlightID and gSelectedSector.

Edited by Guest

Can a crew member be of more than one rank? You have checkboxes for rank. Should it be one rank per crew member?

Thanks.

Yep, just one rank per person. Haven't worked out how to limit it to one choice yet : Will get there soon

So I would need to create the gSelectedSector, and also a new relationship from "Flights to Assignments by FlightID and gSelectedSector".?

I want to be really careful that I don't break it, as it is only just started working how I originally hoped :

Any chance you could show me? I'v had a lot of help with the current setup.

Cheers

Here's a version that I've tooled around with a bit. I've changed key fields to use the naming convention that works for me. As you can see, it brings the IDs to the top of an alpha-sorted list. You were relying on FlightNumber as a UID, and it was user entered.

I also added TOs to the relationship graph using Anchor Buoy, a methodology that I like. It makes it much easier to name TOs and to see their relationships in selection lists.

I've changed gSelectedSector to a global, and built a relationship using it. I've changed the conditional formatting formulas.

The New Assignment script wasn't returning the selectedPersonID. I've fixed that.

hth,

Barbara

General_Declarations2.fp7.zip

Thanks Barbara. I have only just got the chance to have a look at what you provided. the functionality you added works great, but it seems to have disabled some other functionality. I could be missing something simple though....

You can add a flight ok, but in the next portal across you can no longer enter in the sectors for the flight. The portal is setup to allow data entry so maybe the relationship has dropped out?

Cheers

I must have forgotten to turn on Allow Creation of Related in the relationship btw Flights and Sectors. Just edit the relationship btw the TOs Flights and flights_SECTORS to allow creation.

Thanks Barbara, all working great.

My next issue is with Reports, but I'm going to post it here as you are familiar with the project. You can see I have added a "Crew Sector Report" which prints the Sector, with crew names below grouped by their role. This works fine, however I'd like it to do the same sort of thing for each flight. E.g Same presentation that I already have, but instead of listing the Selected Sector, it shows all the sectors.

I can't seem to get it to work. ( I can post in Reports if that's a better idea)

Cheers

Nathan

Copy_of_General_Declarations.zip

Sorry to be uploading again, but I can't seem to be able to edit my posts....

I have half completed what I mentioned above. "Flight Report" prints all the sectors correctly. However, it doesn't list the crew properly or sort by their role.

Also, selecting another flight still prints only the first flight in the system.

Copy_of_General_Declarations2.zip

When you design a sub-summary report think about what's in the body part first. So, if you want the crew members listed for each sector for each flight, then you should base the report on the Assignments table.

Using Assignments as the Layout Setup wasn't working correctly. It wouldnt even open up the report correcty.

I have also tried using Assignments2 which is close to working. If I print a report showing related records, it only shows the selected sector. If I deselect "Show only related records" it shows what I want, but for every flight.

Almost there, just need some help to connect the dots.

Thanks again

Barbara is right - the report should be based on the Assignments table. As far as I can see, your problem is that the relationship between Flights and Sectors is using incorrect matchfields (it should be kP -< kF, IMHO). Once you fix that, you should be able to GTRR to Assignments (match CURRENT record only, if you want to report on a single flight).

You'll need to rework the report layout extensively, and adjust the script's sort order to match.

Awesome. That fixed it.

Cheers

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.