locked
I get Invalid XAML Exception in Blend 4 Beta when trying to use Behaviors or FluidLayout inside a DataTemplate of default Controls RRS feed

  • Question

  • I'm using Blend 4 Beta on Windows 7 x64 (the same thing is tested on the x86 version so the problem is not with the OS).

    This issue wasn't present in the Blend 4 Preview. The strange thing is that when i create a new application and repeat the scenario inside the DataTemplate this Exception is NOT thrown. Also when using Behaviors, activating FluidLayout or adding anything that uses the namespace  (xmlns:ei="http://schemas.microsoft.com/expression/2010/interactions") outside the DataTemplate nothing is wrong, it ONLY happends inside the DataTemplate of the controls ItemsControl, Listbox etc...

    Sample code:

    <VisualStateManager.CustomVisualStateManager>
             <ei:ExtendedVisualStateManager/>
    </VisualStateManager.CustomVisualStateManager>

    <i:Interaction.Triggers>
             <i:EventTrigger EventName="MouseLeftButtonDown">
                     <ei:ControlStoryboardAction/>
             </i:EventTrigger>
    </i:Interaction.Triggers>

    Other thing that might give you a clue: When i close the solution and open it again the Invalid XAML Exception is not shown in design view, it appears ONLY AFTER Build or Rebuild (The application still runs in the browser and works fine but this error is so annoying and it will be the same thing as designing in Notepad if i can't get rid of it - it hides the Objects and Timeline tree and the Properties panel)

    Any ideas what might cause this Exception and how can i solve this problem ?!

    I would appreciate any help. Thanks

    Monday, March 29, 2010 10:49 AM