skip to Main Content

Visual Studio Code – C# MAUI Async function catches for Windows but not for Android

I have the following code: public partial class MetricsPage : ContentPage { public MetricsPage() { InitializeComponent(); using var client = new HttpClient(); client.BaseAddress = new Uri("http://example.com"); client.Timeout = new TimeSpan(0, 0, 3); client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Api-Key", "<my_key>"); client.DefaultRequestHeaders.Accept.Add( new MediaTypeWithQualityHeaderValue("application/json"));…

VIEW QUESTION
Back To Top
Search