Note that there are some explanatory texts on larger screens.

plurals
  1. PODependencyProperty of Type Delegate
    primarykey
    data
    text
    <p>I have created an attached behavior that is used to execute a Delegate of type <code>Func&lt;bool&gt;</code> when the behavior is invoked. Below is the dependancy property definition.</p> <pre><code>public static readonly DependencyProperty SendToDetailBehaviorProperty = DependencyProperty.RegisterAttached("SendToDetailBehavior", typeof(Func&lt;bool&gt;), typeof(ListDetailAspectSendToDetailBehavior), new UIPropertyMetadata(null, SendToDetail)); </code></pre> <p>I have it working just as expected however in my XAML I get the following error, preventing the designer from loading.</p> <blockquote> <p>Property 'SendToDetailBehavior' was not found or is not serializable for type 'SortableListView'</p> </blockquote> <p>Below you will find the xaml.</p> <pre><code>&lt;Controls:SortableListView Grid.Row="0" Grid.Column="0" Name="lvwLocations" MinHeight="150" MinWidth="{Binding Path=BusinessObject.Locations, ValidatesOnDataErrors=true, Converter={StaticResource AlwaysReturn1Converter}, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}" Style="{DynamicResource SortableListViewStyle}" ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" IsSynchronizedWithCurrentItem="True" **behaviors:ListDetailAspectSendToDetailBehavior.SendToDetailBehavior="{Binding Path=LocationListDetail.SendFocusToDetail}"** ItemsSource="{Binding Path=LocationListDetail.MasterList}" SelectedItem="{Binding Path=LocationListDetail.DetailItem, Mode=TwoWay}" MouseDoubleClick="lvwLocations_MouseDoubleClick"&gt; </code></pre> <p>If I change the underlying type of the Dependancy Property to a <code>bool</code> for example, the error goes away. </p> <p>As I said the attached behavior is working, only the designer blows up. I have looked for documentation on this and have come up empty. I am hoping someone here has some insight.</p> <p>Thanks, BDN</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload