Here's some code for ItemsSource:
Xamarin.Forms – ControlTemplates (MVVM)
Xamarin.Forms Responsive Layout from Device Rotation
Intro This is a brain dump on implementing a responsive layout based on a device being in Portrait or Landscape mode. In summary, I used a ContentView's ControlTemplate to host a layout that depends on a device being in Portrait or Landscape mode. In addition, I then overrode the OnSizeAllocated method on the ContentPage. XAML …
Continue reading "Xamarin.Forms Responsive Layout from Device Rotation"
Implementing ValueConverters in F#
I recently learned how to implement ValueConverters in F#. In case you haven't realized, I have been experimenting with F# on my off time so that I can be a better developer and thus increase both my worth and influence within the software development industry. ValueConverters serve as translators for data binding. Specifically, they convert values of one …
Story Siloed Architecture
Intro Imagine implementing user stories as independent modules within an application. What if we could implement each user story in complete isolation from the other user stories within our application? What if we could test each user story in complete isolation from the other user stories within our application? What if we could rewrite an implementation of a user …
Xamarin.Forms: Camera Integration
Intro In the last post, I wrote a tutorial on how to integrate Google Maps and GPS services into a Xamarin.Forms app. This post will focus on camera integration with Xamarin.Forms. In this post I will provide code (referenced from XF Labs) that will enable your Xamarin.Forms app to take and view photos. The following …
Xamarin.Forms: Integrating Maps and Location Services
Intro Within Xamarn.Forms, we may find ourselves having to implement a feature that's dependent on a map and/or GPS. In order to implement this for Android and provide other controls to manage related services, we must implement a native Android page within our Xamarin.Forms app. In this post I will demonstrate how to load a …
Continue reading "Xamarin.Forms: Integrating Maps and Location Services"
Xamarin.Forms: Displaying a Native Android Page
Intro Within Xamarn.Forms, we may find ourselves having to show a custom page per device platform (i.e. IOS, Android, etc.) In my case, I needed to display a content page that had a map along with some other controls. In this post I will demonstrate how to load a native android page within a Xamarin.Forms …
Continue reading "Xamarin.Forms: Displaying a Native Android Page"
Xamarin.Forms: Portable Class Library (PCL) and Code Coverage
.NET developers have used the [ExcludeFromCodeCoverage] attribute to focus validation on their business logic's code coverage. However, when building Xamarin.Forms applications, the [ExcludeFromCodeCoverage] attribute is not supported within the Portable Class Library. To workaround this issue, use the [DebuggerNonUserCode] attribute instead. Be aware that the debugger will be disabled for the code associated to this attribute. As a result, …
Continue reading "Xamarin.Forms: Portable Class Library (PCL) and Code Coverage"
Xamarin.Forms: Unit Test a Confirmation Dialog
Intro It is absolutely essential to protect our code base from breaking changes. “We must protect this house!” One of the most important tests that need to be performed in software is testing user confirmations. Many professional debuggerers only know how to test this by launching the actual application to display a confirmation dialog. There …
Continue reading "Xamarin.Forms: Unit Test a Confirmation Dialog"