Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

After PopModalAsync Buttons on Main View show first letter only (attached Image and Code Snippet)

$
0
0

Greetings,
I have this very strange behavior.

protected override async void OnAppearing()
{
try
{
var contactsController = new ContactsController();
if (await contactsController.HasLocalContacts())
{
await Navigation.PopModalAsync();
}
else
{
await Navigation.PopModalAsync();
await Navigation.PushModalAsync(new SettingsPage(contactsController));
}
}
catch (Exception exception)
{
DisplayAlert("Error Loading Data", "Please make sure that you have Internet Connectivity and try again", "Okay", "");
}
base.OnAppearing();
}

This code is from a splashscreen raised with Navigation.PushModalAsync

Now, the HasLocalContacts call from the ContractsController is where the weird behavior occurs.
When I simply return true (harcoded) everything is fine and dandy (but useless obviously).

When I implement my actual behavior please look at the Emulator in the actual-behavior attached Image. The buttons only show their first letter.

both attach images show the emulator results with the changes to the controller class (the OnAppearing method is never changed)

Please help!
Geo


Viewing all articles
Browse latest Browse all 58056

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>