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

I am sure this is simple, but I can't figure it out. Need to extract the file name after 'remote:' and before 'FILE'

 

remote:photo_todo.rtf

FILE:jbDeliverables/deliverable_list_document/photo_todo.rtf

 

Thoughts?

Set variable,   $pos1  the location of Remote:, ie  use  Position ( text ; searchString ; start ; occurrence )  

set variable, $pos2 the location of file.

grab everything in between with  Middle ( text ; start ; numberOfCharacters )    numberofcharacters if difference between $pos's, dont forget to take into account the length of the words

 

now run through a loop to get multiple filenames. increment occurrence by 1 in loop.

To be more specific in case you are new to FM (since you do not show your self-rating), the calculation might look like this:

Let ( [
start = Position ( text ; "Remote:" ; 1 ; 1 ) + Length ( "Remote:" ) ;
end = Position ( text ; "File:" ; 1 ; 1 ) - 1
] ;
Trim ( Middle ( text ; start ; end - start ) )
)

You can then use it in script to loop as indicated by No_access or you can use Replace Field Contents.  Be sure to back up first. :^)

 

Also, are you really still on version 8?  If not, it will help if you update your profile.  Thank you!

  • Author

Thanks LaRetta and No_access that did the trick. Updated my profile too...haven't been here in a while.

You can try it this way.

 

Trim (
	Let ( [
			prefix = ":" ;
			suffic = "." ;
			start = Position ( YourField ; prefix ; 1 ; 1 ) + Length ( prefix ) ;
			end = Position ( YourField ; suffic ; start ; 1 )
		] ;
		Middle ( YourField ; start ; end - start )
	)
)

Hi Lee!!

 

The only reason it is recommended to include text instead of focusing on just the colon or period is that those single characters can exist in other locations within the string.  By including everything which you know is unique to the string, you can guarantee getting the correct results every time.

Hi LaRetta,

 

I posted this before I saw you had posted. 

 

You are right about, the more start and end information you can use, the better.  Anyway, this gives s/he a variant on the formula that can help them in the future.

Absolutely! Variants of a technique or calculation also shows the underlying principle a bit more.   :^)

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.