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.

Calculated Value List

Featured Replies

  • Newbies

I need to create a value list for a drop down to be able to choose the Graduation Year for students. I'd like the list to include: this year, this year +1, this year + 2, and so forth. I don't want to do fixed values since list will advance each year.

 

Thank you

Year(GetCurrentDate) I believe . . . +1, +2 etcetera.

You can write a script that is executed OnFirstWindowOpen (or is called by another, generic start script) and compares the values of a stored field in a one-record Control table with the contents it should have based on the current date, and updates its contents if they differ.

Go to Layout [ Control ( Control ) ]
Set Variable [ $yearList ; 
Let ( 
y = Year ( Get ( CurrentDate ) ) ;
List ( y ; y + 1 ; y + 2 /* andSoForth */ )
)
]
If [ Control::yearList ≠ $yearList ]
  Set Field [ Control::yearList ; $yearList ]
End If

Base your value list on that field. OTOH …

 

I don't want to do fixed values since list will advance each year.

 

… that's once (1x) a year. Posting this message, reading the replies and implementing this or any other suggested method will probably eat up any savings in time you could ever hope to gain by automating this process. But then of course, we're programmers …  :laugh: 

 

Year(GetCurrentDate) I believe . . . +1, +2 etcetera.

 

The problem I see: if you index that, it won't update; if you don't index it …

  • Author
  • Newbies

Thanks. I agree that manually updating is quick (and I've spent too much time on this already), but I'm 72 and may not work forever at school. Will someone else update? Who knows.

 

Yes, indexing is the problem. I created a list value, but FM whined that it wouldn't index.

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

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.