Vishful thinking…

Avoid using properties called “Name” in your Silverlight classes

Posted in Silverlight by viswaug on March 31, 2009

This is something that I ran into a little while ago. I had a property called “Name” in one of my Silverlight classes that was getting created in XAML. When I created the class in XAML all the properties on the class got applied as set in XAML except for the “Name” property. As usual, I assumed I was doing something wrong and was trying to figure out where i messed up. After, trying to debug this for a while and loosing my self-esteem as a developer, I realized that Silverlight just doesn’t like setting the property called “Name” in XAML. It works fine when you set it in code. It is just XAML that messed with my head for a little while there. So, avoid the mistake I made and retain some sanity.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: