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.

Script to specify find request - based on calcluated criteria

Featured Replies

Greetings, So I have a date field which contain lots of date records. I want a button to perform a script to find only dates for this year only on the mentioned field. I am having difficulties trying to Specify a Find Request on what criteria to put.. I can easily put 2020 as a find criteria but I don't want to do this every year, so I need something like "Year(Get(Currentdate)" as a find criteria but it won't allow me giving me the error "The Value of this field must be a valid date in the range of years 1 to 4000 and should look like 25/12/2013".

So I guess my question is how to put the find criteria as today's year?

How can I do this?

You cannot enter calculations into find criteria directly. You must do:

Enter Find Mode [ ]
Set Field [ YourTable::Datefield; Year ( Get ( CurrentDate ) ) ]
Perform Find [ ]

Or do:

Set Variable [ $thisYear; Value:Year ( Get ( CurrentDate ) ) ]

and then use the variable as the find criteria in your find request.

 

---
P.S. Please edit your profile to reflect your version and OS so that we know what you can use.

  • Author
16 hours ago, comment said:

You cannot enter calculations into find criteria directly.

Thank you for clearing this out.. so you can do it in-directly using the method below. I have a lot to learn.

16 hours ago, comment said:

Set Variable [ $thisYear; Value:Year ( Get ( CurrentDate ) ) ]

and then use the variable as the find criteria in your find request.

Thanks a lot... its exactly what I need.

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.