cinch

Getting Unity to Resolve views in XAML

◇◆丶佛笑我妖孽 提交于 2019-12-09 00:48:25
问题 I'm starting out with MVVM, and I'm starting to understand things. I'm currently experimenting with the Cinch framework, though I'm not committed to it as of yet. I was injecting the ViewModels into the Views using by having a reference to the ViewModel in the codebehind of the view, with the property having a [Dependency] on it, and in the setter it sets the DataContext to the right view, using Unity. Neat trick, I thought. I'm trying to get my app to work as a single Window, with injected

Getting Unity to Resolve views in XAML

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-30 22:05:49
I'm starting out with MVVM, and I'm starting to understand things. I'm currently experimenting with the Cinch framework, though I'm not committed to it as of yet. I was injecting the ViewModels into the Views using by having a reference to the ViewModel in the codebehind of the view, with the property having a [Dependency] on it, and in the setter it sets the DataContext to the right view, using Unity. Neat trick, I thought. I'm trying to get my app to work as a single Window, with injected views (As opposed to multiple windows and dealing with opening\closing them) I changed my views from