How can I use ContentPropertyAttribute with C++/WinRT? I find some help in github and msdn,
but regretfully when I code like this
namespace App3
{
[bindable]
[default_interface]
[Windows.UI.Xaml.Markup.ContentPropertyAttribute("Actions")]
runtimeclass EventBehavior : Windows.UI.Xaml.DependencyObject, Microsoft.Xaml.Interactivity.IBehavior
{
EventBehavior();
static Windows.UI.Xaml.DependencyProperty SourceObjectProperty{ get; };
Object SourceObject{ get; set; };
static Windows.UI.Xaml.DependencyProperty EventNameProperty{ get; };
String EventName{ get; set; };
static Windows.UI.Xaml.DependencyProperty ActionsProperty{ get; };
Microsoft.Xaml.Interactivity.ActionCollection Actions{ get; };
}
}
it doesn't compile. The error is
MIDL2009 [msg]undefined symbol [context]: Windows.UI.Xaml.Markup.ContentPropertyAttribute
BlankApp4 C:\Users\Cool-\source\repos\BlankApp4\BlankApp4\EventBehavior.idl
So, my question is how to use ContentPropertyAttribute?