[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

[Solved] What should I do about unstable packages in Visual Studio 2017, error: was restored using ‘.NETFramework,Version=v4.6.1’ instead of target framework

That’s a warning message, not an error message, and this is by design. Please refer to https://docs.microsoft.com/en-us/nuget/reference/target-frameworks for target framework information. .NET Standard 2.0 and .NET 4.6.1 have a huge surface area overlap. For this Visual Studio and NuGet have added the concept of a fallback framework, where when a user tries to install a … Read more