Home › Forums › Software Development › WPF, The Design view cannot display correctly because some custom elements have
- This topic has 1 reply, 2 voices, and was last updated 8 years, 10 months ago by
Patrik [Tobii].
- AuthorPosts
- 08/02/2015 at 03:54 #2486
Stan Yu
ParticipantI have built an simple wpf app by migrating the gaze aware app from sample code, everything works just fine, I can build the app and run it, the control that has the gaze behavior responses the eye gaze correctly. However, in the WPF desing view, it can not display the design layout but shows the message:
Build the Project to update Design view.
The Design view cannot display correctly because some custom elements have not yet been built.It will only display correctly if I remove the style from resource:
<Style x:Key=”EyeXGazeAwareElement” TargetType=”FrameworkElement”>
<Setter Property=”eyeX:Behavior.GazeAware” Value=”True” />
<Setter Property=”eyeX:Behavior.GazeAwareDelay” Value=”0″ />
</Style>
<Style x:Key=”EyeXGazeAwareButton” BasedOn=”{StaticResource EyeXGazeAwareElement}” TargetType=”Button”>
<Setter Property=”Background” Value=”LightSteelBlue” />
<Style.Triggers>
<Trigger Property=”eyeX:Behavior.HasGaze” Value=”True”>
<Setter Property=”Background” Value=”DeepSkyBlue” />
</Trigger>
</Style.Triggers>
</Style>Due to the reason that the visual studio says: The name “Behavior” does not exist in the namespace “clr-namespace:EyeXFramework.Wpf;assembly=EyeXFramework”.
the eyex namespace is defined in the xmlns:eyeX=”clr-namespace:EyeXFramework.Wpf;assembly=EyeXFramework” which can ben recognized, but not its behavior.
Any reason that WPF designer is not able to refer to the assemble resource correctly ?
09/02/2015 at 10:09 #2497Patrik [Tobii]
ParticipantHello Stan!
I have not been able to reproduce this error, but after reading this Microsoft Connect article (and the workaround) I suspect this might have something to do with a platform target mismatch.
Are you perhaps referencing the x86 Tobii.EyeX.Client.Net.dll in a project that uses a x64 platform target (or vice versa)?
Best regards
Patrik - AuthorPosts
- You must be logged in to reply to this topic.