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.

Sort when writing out a valuelist?

Featured Replies

  • Newbies

Hey all,

I'm in a bit of pinch where I am depending on a dynamically-generated value list to match a dynamically-generated valueID list. The problem is that FM writes out the text values in Alphabetical order and writes out the IDs in ascending order. Here's the code and what I am seeing:

var feature_list = new Array(

"-No Selection-",[FMP-ValueList: ID, List=FeatureCategories] "[FMP-ValueListItem]",[/FMP-ValueList]" ");

var id_list = new Array(

"",[FMP-ValueList: ID, List=FeatureCategoryIDs]

"[FMP-ValueListItem]",[/FMP-ValueList]" ");

The "FeatureCategories" come out:

"a", "b", "c"

The "FeatureCategoryIDs" come out:

"1", "2", "3"

The problem is that the ID of FeatureCategory "b" is "3." This appears sorted properly in FM, but not in the HTML. Is there anyway to specify a sort when writing out a valuelist?

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.