Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 6227 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

If Anyone can help, I'd greatly appreciate it.

I want to make a field calculation. And I want the calculation to look at another field in the same record and take 2 letters out of the name and add numbers to it

example:

"name" field = Adventure Sport

I want the "number" field to read "AS001". I can't find the function to actively select the first letter of each word. Can you help me?

Thanks.

Posted

Hi

what if the field contains only a word ?

and if contains more than two ?

BTW: this calculation...

Filter ( Proper ( Lower ( text ) ) ; "ABCDEFGHIJKLMNOPQRSTUVXYWZ" )

... will give you the first letter of each word.

Than you have to keep the first two with:

Left ( Filter ( Proper ( Lower ( text ) ) ; "ABCDEFGHIJKLMNOPQRSTUVXYWZ" ) ; 2 )

... but what you wish if the word is only one ?

If you think to use a fixed char ( like "X" ) than the calculation becomes:

Left ( Filter ( Proper ( Lower ( testo ) & " X" ) ; "ABCDEFGHIJKLMNOPQRSTUVXYWZ" ) ; 2 )

Posted

It's a GENERAL method for getting the initials. If you have input that's guaranteed to be in title case, you don't need it. It also might need other adjustments if you're dealing with special cases like names (d'Arcy, Smith-Jones, etc.). But it's a great way to avoid a recursive calc.

Posted

Could someone explain to me the need for the Lower()?

Take a omnipresent name here, like LaRetta : , will the R come thru as well, same would McCain give two which would allow both M and C thru.

So by lowering every char first and then Proper( afterwards will only the leading char in each word be capitlaized.

--sd

Posted

I would think that Proper(text) would always be the same as Proper(Lower(text)). Is there an example where that isn't true?

In my FM9A Data Viewer,

Proper("LaRetta") returns Laretta.

Proper("McCain") returns Mccain.

Posted

Could someone explain to me the need for the Lower()?

good point !

No need for Lower, but some needs for other accented chars into the string

This topic is 6227 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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