Because we want to show the input photo in the input view, we need to convert it from byte[] to Xamarin.Forms.ImageSource. We will do this in a value converter that we can use together with the binding in the XAML by going through the following steps:
- Create a new folder called Converters in the HotDogOrNot project.
- Create a new class called BytesToImageConverter.
- Add and implement the IValueConverter interface, as shown in the following code:
using System;using System.Globalization;using System.IO;using Xamarin.Forms; public class BytesToImageConverter : IValueConverter{ public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { throw new NotImplementedException(); } public object ...