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.

Define field to show all value list items

Featured Replies

How can I define a field to show all value list items?

It is not clear to me if you mean, attach a value list to a field, or have the field equal the value list in some way.

To attach a value list to the field, first create the field and the value list. Then go into Layout Mode, Select the Field, Go to Menu >> Format >> Field Format. In the dialog box, select the type of "Style" you want for your value list (it defaults to Pop up list), then select the value list in the drop down menu on the right.

If it is the other, there was a recent thread (yesterday and today) called "Checkbox "views" ". It's located in the Topic area for Value Lists. While you are there, take a look around at some of the other subjects, maybe one or two of them will be helpful.

Lee

Or Get ( ValueListItems ) to make the field equal to the contents of the VL.

J

  • 4 weeks later...

I tried the function:

ValueListItems ( "Respondents" ; "Names" )

According to the documentation, this calc should have the field show all the contents of a particular value list, each item seperated by a return.

Cant get it to work. The only thing that shows up in the field is a question mark ?

Anyone know how to get this to work?

Larry

Are its storage options set to "Do not store"? Is it a Text result? Are the names exactly right?

Thanks for the hint. Forgot that the value could not be stored.

Larry

I have something to add to this. I have recently used the valuelistitems function and it does not update until a new record is created. I have it set as a global field. Any ideas? Is this how it is supposed to be? I am using version 7.0v3.

-Tanner

You need to enclose the function within Evaluate or else it will only recalculate when a new record is created.

Evaluate( "ValueListItems( Get(FileName); "yourvaluelist" )"; field_on_which_list_is_based )

Whenever field_on_which_list_is_based is changed, the calculation will evaluate. In order to refresh the data onscreen and for immediate calculations, you will need a script to set field_on_which... to itself and Commit Records/Requests.

Ooohh, Thank you. That works perfectly. One more question if you don't mind. what are the back slashes for?

A backslash is an escape character in FM 7. It treats the character immediately following it literally. If it weren't for the backslash before the double quotes, each would be treated as a text delimiter instead of as a literal double quote. So "ValueListItems( Get(FileName); " would be seen as text, yourvaluelist would be seen as a field name, and " )" would be seen as text. It basically makes it easier than typing four double quotes for each double quote that you want to appear within the text, as is necessary in previous versions.

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.