catel

Binding ViewModel property in DataGridTextColumn

半世苍凉 提交于 2019-12-11 19:33:23
问题 For an application I need to create a DataGrid with a DataGridTextColumn which has MultiBinding . The first Binding uses a property given in the ItemsSource, the second Binding should use a Property from my ViewModel. <DataGridTextColumn Header="Hourly wage" SortMemberPath="HourlyWage"> <DataGridTextColumn.Binding> <MultiBinding StringFormat="{}{0}{1}"> <Binding Path="HourlyWage" /> <Binding Path="CurrencyUnit" /> </MultiBinding> </DataGridTextColumn.Binding> </DataGridTextColumn> In that

how to Step through Catel code while debugging ?

依然范特西╮ 提交于 2019-12-11 19:27:58
问题 After adding Catel implementation to one of my views(mainPage) in my project I have a bug that crashes my Silverlight project. The only indication I have is :" A first chance exception of type 'System.NullReferenceException' occurred in Catel.MVVM " (just about after setting the RootVisual~) - I can't find what I'm doing wrong, and since I am planing on a long-term relationship with Catel I thought that stepping through Catel code might come in handy, so I tried and failed in all the

WPF Treeview Using Catel 4

徘徊边缘 提交于 2019-12-11 08:12:24
问题 Can anyone guide me in using Catel 4 and a WPF TreeView control? I'm trying to create something like the VS solution explorer. I have created models and VMs for each level of the tree. When I add a hierarchical data template (HDT) and use the VM types for the DataType parameters, I get a tree showing the top-level collection member types. That is, WPF couldn't match the ItemsSource collection types to my HDT. If I change the HDT to use the model types, the TreeView behaves properly, but now

DataWindowButton CanExecute not firing, Catel 4.0

时光毁灭记忆、已成空白 提交于 2019-12-11 07:50:06
问题 I have just updated a project from Catel 3.4 to Catel 4.0 and a custom apply button that had been working now never gets enabled. AddCustomButton(new DataWindowButton("Apply", ExecuteApply, canExecuteApply)); In Catel 3.4 the canExecuteApply got called when the window got focus or any control was changed. In 4.0 it gets called twice when the window is created and never again. I suspect this has something to do with the IViewPropertySelector part of the update guide, however registering the