Skip 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.

Checking for a string inside a string

Featured Replies

Okay, first let me say that this is not going to be an actual 'Find', and I expect all of this to be done in Browse mode (hopefully).

Here's my situation:

When a user creates an invoice, they have to specify how the entire order will be shipped. This is done by entering it into a SHIP field. There are many ways that the order can be shipped, such as by freight, UPS ground, ect... But the user needs to enter extra data if they choose to ship by UPS. The type of UPS shipment may be different, such as UPS ground, UPS air, UPS dropshipment, etc... I'm wondering if there's any way to create a script that will check to see if the SHIP field starts with UPS, and if it does, then go to another layout for extra data input.

I don't think there should be an extra dropdown menu for UPS shipments, since the user may not realize they have to enter UPS, and then go to another field to choose the rest of the shipment type. Is there just a way to get the first word of a string so that it can be compared? Thanks.

Edited by Guest

Hi,

Have you tried Leftwords (text;numberofWords)? Here is the example from FM's help:

LeftWords("Plaid Canvas Suitcase";2) returns Plaid Canvas.

LeftWords(Name;1) returns Sophie, when the Name field contains Sophie Tang.

Hope that answer your question.

  • Author

Hmm. As long as it delimits the words by spaces, it should do exactly what I need. Thanks.

You're right. Also, if it's delimited by another string such as | (pipe) or another unique char, you can try to use the Substitute function to change the unique delimiter to the space. :]

Spaces are not the only word delimiters, FYI. Also check out some of the other text functions such as Left, Position, and PatternCount.

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

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.