I am trying to use a DataWindow in Catel 3.0 and have run into a few minor issues:
1. I right-click on my Views folder and then click Add and then New Item. In the Add New Item dialog I select Catel under Installed Templates and then Window (WPF with Catel, logic in view base) on the right. I give it the appropriate
name and click Add.
I immediately get an error indicating an invalid namespace. In the xaml, a namespace entry has been included for: xmlns:ViewModels="clr-namespace:MedicalLog.Views.ViewModels"
The correct namespace should be just MedicalLog.ViewModels. Is this a bug or am I doing something wrong? Correcting the namespace fixes the error.
2. The created Window inherits from DataWindow<SettingsViewModel> but when I build I'm getting a warning indicating that this class is obsolete and that I should use the non-generic DataWindow class instead. Is there a newer version of the template
that doesn't use the obsolete class?
I changed it so that the class inherits from DataWindow instead and removed the x:TypeArguments="ViewModels.SettingsViewModel" entry from the xaml and then was able to build without getting the warning. If the non-generic DataWindow is used,
it seems that the ViewModels namespace entry that caused the first issue is no longer necessary.
3. When I run the app and open the view, the OK and Cancel buttons appear at the left bottom of the form and are sized to fit their contents instead of being the same size which looks odd. In the documentation, it indicates that the buttons are
supposed to be same-sized and right-aligned. Has this changed? The documentation also indicates that styles are available but I couldn't find any examples of how to use them. If you could let me know how to do that I would appreciate it.