What’s new for Windows 8 Devs Part 2 David Burela Regional Tech Evangelist, Infragistics
Agenda Manually updating the UI Data binding ViewModels INotifyPropertyChanged / ObservableCollection<> DataTemplates Commands Portable class library Caliburn.Micro
Manually updating the UI Demo Manually updating the UI
Why MVVM? Separates UI from business logic View ViewModel Model Model Main View.Xaml Main ViewModel.cs
Demo ViewModels
Commands Decouples events from invoked logic TextBlock Total Button View TextBlock ViewModel Total Model Model Button Increment()
Demo Commands
Cross platform Reusable code Windows 8 Windows Phone WPF Silverlight iOS / Android (via MonoTouch / MonoDroid)
Cross platform Windows 8 View Windows Phone View Model ViewModel Silverlight View Model WPF View …
Portable class library Demo Portable class library
CustomerOrders ViewModel.cs MVVM Architecture sample View ViewModel Model Model CustomerOrders View.Xaml CustomerOrders ViewModel.cs REST OData WCF Customer Orders CurrentCustomer List<Orders>
Organising files Views/ViewModels Folder per feature
DataTemplates List View Grid View Grouped data © 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.
Demo DataTemplates
Caliburn.Micro
Demo Caliburn.Micro
1/17/2019 7:19 AM © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. © 2009 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.