Thursday, August 27, 2009

Beware of the dot when parsing XAML

"." != ","

As I was working today on some dynamic datatemplates, I encountered a strange XamlParseException. For one or other strange reason a custom XAML file couldn't be parsed by  the XAML engine. After some investigation, I could trace the source of my problem to some positioning coordinates I provided in my code. If I removed it, everything worked nicely.
So what was the reason? I'm working at a Belgium company where all the environments are in Dutch. Where in America a '.' is used as a decimal separator, in Belgium we're using the ','.  Luckily for us, some other people encountered the same issue and Microsoft provided a hotfix.
Thank you, Microsoft!