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

Does anyone have a calculation that will conver double barrel surnames to proper case - for example Smith-Davis (not Smith-davis) also O'Neill not O'neill.....there maybe others but has anyone got a solution that handles all these?

Thanks

If(Left(LeftWords(Text,1),2)="O'",

"O'" & If(PatternCount(LeftWords(Text,1),"-") =1,

Proper(Middle(Text,3,Position(Text,"-",1,1)-2)) &

Proper(Right(LeftWords(Text,1),Length(LeftWords(Text,1)) -

Position(Text, "-",1,1))),

Proper(Middle(Text,3,Length(LeftWords(Text,1))-2))),

If(Left(LeftWords(Text,1),2)="D'","D'" &

If(PatternCount(LeftWords(Text,1),"-") >=1,

Proper(Middle(Text,3,Position(Text,"-",1,1)-2)) &

Proper(Right(LeftWords(Text,1),Length(LeftWords(Text,1)) -

Position(Text, "-",1,1))),

Proper(Middle(Text,3,Length(LeftWords(Text,1))-2))),

If(Left(LeftWords(Text,1),2)="Mc","Mc" &

If(PatternCount(LeftWords(Text,1),"-") =1,

Proper(Middle(Text,3,Position(Text,"-",1,1)-2)) &

Proper(Right(LeftWords(Text,1),Length(LeftWords(Text,1)) -

Position(Text, "-",1,1))),

Proper(Middle(Text,3,Length(LeftWords(Text,1))-2))),

If(PatternCount(LeftWords(Text,1),"-") =1,

Proper(Left(Text,Position(Text,"-",1,1))) &

Proper(Right(LeftWords(Text,1),Length(LeftWords(Text,1)) -

Position(Text, "-",1,1))),

Proper(LeftWords(Text,1))))))

HTH

Lee

cool.gif

Middle ( "isdnklWOW!!!nmklcasdnfc" , 7 , 6 )

Try:

If (PatternCount (Test_Name;"-") = 0 ; Test_Name ;

( Let ( [ pos = Position(Test_Name ; "-" ; 1 ; 1) + 1; letter = Middle(Test_Name;pos;1)] ; Replace (Test_Name; pos;1;TextStyleAdd(letter;Uppercase)))))

Probably Queue could come up with something simpler, but at least the above works.

  • Author

Thanks guys!! btw I'm using Fm6

Here is another method:

If (PatternCount(Test_Name ; "-" ) = 0 ; Test_Name ;

Let ( [ pos = Position(Test_Name ; "-" ; 1 ; 1 ) + 1 ; letter = Middle (Test_Name; pos;1)] ;

Replace (Test_Name ; pos ; 1 ; Upper(letter))))

Versions before 7 don't have the Let function, so in that situation just substitute the full strings for pos and letter.

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.