C# 如何在WPF中设置与DocumentPageView.DocumentPaginator的绑定
如何在WPF中绑定DocumentPageView?C# 如何在WPF中设置与DocumentPageView.DocumentPaginator的绑定,c#,wpf,xps,xpsdocument,C#,Wpf,Xps,Xpsdocument,如何在WPF中绑定DocumentPageView? 我的代码: 源是DocumentPaginator的类型。 错误是: 错误1无法在“DocumentPageView”类型的“DocumentPaginator”属性上设置“Binding”。只能对DependencyObject的DependencyProperty设置“绑定” 请帮帮我。 Tnx…您的错误消息说明了一切。只能将绑定应用于DependencyProperty。DocumentPaginator不是DocumentPage
我的代码:
源是DocumentPaginator的类型。
错误是:
错误1无法在“DocumentPageView”类型的“DocumentPaginator”属性上设置“Binding”。只能对DependencyObject的DependencyProperty设置“绑定”
请帮帮我。
Tnx…您的错误消息说明了一切。只能将绑定应用于DependencyProperty。DocumentPaginator不是DocumentPageView的从属属性,因此您无法绑定到它。您的错误消息说明了一切。只能将绑定应用于DependencyProperty。DocumentPaginator不是DocumentPageView的DependencyProperty,因此无法绑定到它
<DocumentPageView DocumentPaginator="{Binding Source}"></DocumentPageView>