Example #1
0
        async private void SelectLocal_Clicked(object sender, EventArgs e)
        {
            try
            {
                var result = await FilePicker.PickAsync();

                if (result != null)
                {
                    var stream = await result.OpenReadAsync();

                    var bytes = new byte[stream.Length];
                    await stream.ReadAsync(bytes, 0, bytes.Length);

                    await ota.CheckUpdateLocal(bytes);
                }
            }
            catch (Exception ex)
            {
                // The user canceled or something went wrong
            }
        }