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.

Featured Replies

Can you help?

I am trying to use a calculation to populate a repeating field. I did it with a script... and now I want to do it as a calc to speed up the process.

I have a file name... I'm trying to identify all the positions of the character / in the file path. So I have a repeating field with 15 repeats. I set the field as a calc... and then the first calc is

Position ( server_string ; "/" ; 0 ; 1 )

Works great, now I want repeating field 2 to grab the position of the 2nd instance, repeat 3 to grab the position of the 3rd instance and so on.

I know how to get data from repeating fields, but how do I put the data in it as part of the calculation?

thanks for any help.

steve

yep, that is the problem with repeating fields. there's GetRepetition, but there's no SetRepetition!

you could poke around some more with the Extend function, only to find yourself wanting to add some more repetitions later, or changing the logic. THEN, you might eventually come to the point where all this stuff becomes hard to read and maintain. that's why just about everybody will tell you to add a related table instead.

most people use repeating fields only to store some graphics for interface usage or similar things, but not data that needs to be manipulated.

just my 2c.

stefan

Position ( server_string ; "/" ; 0 ; 1 )

Works great, now I want repeating field 2 to grab the position of the 2nd instance, repeat 3 to grab the position of the 3rd instance and so on.

Try =

Position ( server_string ; "/" ; 1 ; Get ( CalculationRepetitionNumber )  )

  • Author

Thanks for the heads up. Using the calculationrepeitiionNumber is doing the trick. Just FYI, I'm not using it for dynamic data... but am using the field to break apart a long path name to feed data to individual calculation fields that connect to the related tables.

Thanks for the tips gang.

s

yep, that is the problem with repeating fields. there's GetRepetition, but there's no SetRepetition!

Functions return results, they don't set fields.

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.