SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm creating a list with some calculated fields from code that use IF expressions.

fieldCalc.Formula = "=IF([Field1]=0,[Field2],[Field3]&\" (\"&([Field4]/[Field5]*100)&\"%)\")";

Apparently, when used in a SharePoint enviroment with comma for decimal point (like Slovenian), the separators in IF expression must be changed to semicolon, like so:

fieldCalc.Formula = "=IF([Field1]=0;[Field2];[Field3]&\" (\"&([Field4]/[Field5]*100)&\"%)\")";

How do I know what separator to use in my expressions?

share|improve this question
up vote 3 down vote accepted

Formulas and functions depend on the language of your site. It's not just about commas vs. semi-colons, the function names will change too.

You can play with this example:

Change the language, and you'll see how it affects the formula. For example, "IF" will become "ALS" in Dutch.

My examples confirm your rule of thumb: if the comma serves as decimal point in numbers, then use a semi-colon.

share|improve this answer

Try using semi colons by default, i think it should work with them regardless of the language you select.

share|improve this answer
No, unfortunately it doesn't work. – Luc Sep 13 '10 at 11:46

I think that you need first look the beheavior on the Column Setting.

Look this example on my list:

My native language on site is spanish.

=IF([Adherencia Metodologica Valor]="";" ";IF([Adherencia Metodologica Valor]<10;""&[Adherencia Metodologica Valor]&"%";IF([Adherencia Metodologica Valor]>9;""&[Adherencia Metodologica Valor]&"%";)))

I render the HTML content... but this is other thing :)

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.