[Solved] when to use await key word? do I need it in this case?

no you don’t need to do that, you can use .Result if you don’t want to execute your code asynchronously , this code is perfectly fine : private void Button_Clicked(object sender, EventArgs e) { try { var getTokenQ = SecureStorage.GetAsync(“Save_Security_Question”).Result; if ((String.IsNullOrWhiteSpace(getTokenQ) == false)) { } else { } } catch (Exception ex) { DisplayAlert(“Message”, … Read more

[Solved] hierarchy structure xamarin form

I would suggest you use a Grid to achive the layout on the image. here is an example how to use a Grid to achive the desired hierarchy: <Grid> <Grid.RowDefinitions> <RowDefinition Height=”Auto” /> <RowDefinition Height=”Auto” /> <RowDefinition Height=”Auto” /> </Grid.RowDefinitions> <Grid.ColumnDefinitions> <ColumnDefinition Width=”*” /> <ColumnDefinition Width=”*” /> <ColumnDefinition Width=”*” /> <ColumnDefinition Width=”*” /> </Grid.ColumnDefinitions> //TOP … Read more

[Solved] Reset a Radio button inside a Radio group

This is how I did it: It is in C# but I think it is easy to convert it to Java. I used tag to know if this radio button checked before or not. False => It is not checked True => It is checked radiobutton.Tag = false; radiobutton.Click += SingleChoiceQuestionAlternativeClick; Then: private void SingleChoiceQuestionAlternativeClick(object … Read more

[Solved] Downgrade the android version cause error [closed]

This is a bug that will be fixed in an upcoming release. To resolve this, change your Version to a version that is > API 19. https://bugzilla.xamarin.com/show_bug.cgi?id=56272 Otherwise upgrade to 15.3 in your Visual Studio Installer to receive this fix as it is included in Xamarin.Android 7.3.0.27 and above. solved Downgrade the android version cause … Read more

[Solved] How to update backup URL in app? Lets say for example Main URL is missing. How the back up url will accesible?

Have you seen this package Polly Polly is a .NET 3.5 / 4.0 / 4.5 / PCL library that allows developers to express transient exception handling policies such as Retry, Retry Forever, Wait and Retry or Circuit Breaker in a fluent manner. You could use it to catch the WebException then retry or switch out … Read more

[Solved] How to change an Image in a button on clicking the button?

A Xamarin/C# way: var button = FindViewById<Button>(Resource.Id.myButton); button.Click += delegate { button.Text = “Some New Text”; // If your image is a Drawable button.SetBackgroundResource(Resource.Drawable.button_background); // From an asset button.Background = Drawable.CreateFromStream(Assets.Open(“button_asset.jpg”), null); // From an arbitrary path button.Background = Drawable.CreateFromPath(“/sdcard/Download/downloaded_file.jpg”); }; Update: If you are using drawableLeft, drawableRight, etc… in your layout, you can change … Read more