The name “Interaction” does not exist in the namespace “http://schemas.microsoft.com/expression/2010/interactivity”

后端 未结 9 2001
花落未央
花落未央 2021-02-02 06:28

I\'ve used the System.Windows.Interactivity DLL in several projects without any problem. Now in my latest project I can\'t get it to work. I always get the following error:

相关标签:
9条回答
  • 2021-02-02 06:44
    1. Remove any project reference to Microsoft.Expression.Interactions and System.Windows.Interactivity.

    2. Install through Nuget the newer Microsoft.Xaml.Behaviors.Wpf, which replaces the aforementioned references, i.e. open the Package Manager console and type:

      Install-Package Microsoft.Xaml.Behaviors.Wpf ProjectName

    3. In the Xaml-files, replace the xmlns namespaces http://schemas.microsoft.com/expression/2010/interactivity and http://schemas.microsoft.com/expression/2010/interactions with http://schemas.microsoft.com/xaml/behaviors

    0 讨论(0)
  • 2021-02-02 06:44

    I removed the missing references Microsoft.Expression.Interactions AND System.Windows.Interactivity. Then I installed Nuget package Microsoft.SDK.Expression.Blend by Hansan Pringle. This is installed the missing references.

    0 讨论(0)
  • 2021-02-02 06:53

    I had the same problem. What I did was:

    1. Remove Microsoft.Expression.Interactions and System.Windows.Interactivity from the project in Visual Studio while keeping the xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" namespace.
    2. Open the same project in Blend.
    3. Add the correct .net versions of Microsoft.Expression.Interactions and System.Windows.Interactivity back in Blend (in my case it was 4.5).
    0 讨论(0)
提交回复
热议问题