Category: XAML

Moving from WinForms to XAML Runtime on Windows Embedded Compact

I recently found an old set of slides I created for TechEd NZ a few years ago which collected together useful information for moving from Windows Mobile to Windows Phone. It struck me that some of this would also be useful for the Embedded XAML Runtime when considering moving code from a traditional WinForms UI to a XAML based UI using Xaml In The Hand. I’ve modified the table listing controls in both UI worlds and added it to the Knowledge Base here:-

While most of this still applies to Windows Phone (and with a few further changes Windows Store apps) there are items here which are specific to Windows Embedded Compact – The ComboBox control which doesn’t exist on Phone (although there is a perfectly good alternative), and the MediaElement and WebBrowser controls which don’t exist in the XAML Runtime but for which we have created managed code controls which expose the same XAML and C# interfaces.

WriteableBitmapEx for Windows Embedded Compact 7

I have ported René Schulte‘s excellent WriteableBitmapEx project to run on Windows Embedded Compact 7. The original library supports drawing across various XAML user interfaces – Silverlight, Windows Phone, WPF and Windows 8 Apps. Because XAML In The Hand exposes an object model which matches Silverlight there was very little work required to port, it just needed a new Dll project for .NETCF 3.5 and a reference to the XAML In The Hand DLL. This allows a whole range of complex drawing operations to be performed where using Silverlight Paths and Shapes would be inefficient.

WriteableBitmap for Windows Embedded

Performance will vary more because the range of hardware platforms available for Windows Embedded Compact varies considerably, both in processing power and screen sizes. I’ve tested the code on FreeScale development boards at up to 1024×768 and on the new Motorola WT41N1 Wearable Computer which has a small 320×240 resistive touch display with encouraging results. Writing XAML user interfaces for embedded devices is incredibly easy once you’ve experienced the Windows Phone and desktop tools. With built in support for touch and dynamic layouts and all the animation and data-binding you would expect it allows you to write fluid user interfaces for specialist devices where a consumer phone or tablet would be impractical. More information on XAML In The Hand is available here