Silverlight Tip of the Day #96 – The meaning of AG_E_PARSER_BAD_PROPERTY_VALUE
If you ever run into this error when running your application you might be a bit perplexed by its encrypted meaning.
Looking at the exceptions details you will see something like which really doesn’t help you very much:
System.Windows.Markup.XamlParseException occurred
Message="AG_E_PARSER_BAD_PROPERTY_VALUE [Line: 4 Position: 53]"
LineNumber=4
LinePosition=53
StackTrace:
at System.Windows.Application.LoadComponent(Object component, Uri resourceLocator)
at MapEditor.TerrainTile.InitializeComponent()
at MapEditor.TerrainTile..ctor(Double xLoc, Double yLoc, Double tileRadius)
InnerException:
The Silverlight Team is working to make improvements in error reporting. For now, to better understand what is causing these errors you should take a careful look at your XAML to see if something declared is missing or wrong. For example, say you have an event handler in your XAML that is not anywhere to be found in your code behind. Often I find myself removing an event handler I no longer want in my code behind but forgetting to remove it in my XAML as well.
Now you know (if you didn’t already).
--Mike