Handling button clicks is super important to build any app, here is how do do it from the XAML file.
All in Xamarin
Handling button clicks is super important to build any app, here is how do do it from the XAML file.
It could be a bit of a pain to try to use Images as buttons, for those scenarios when you needed to display a certain image but also needed the user to be able to click on it, with all that that implies. A nice animation, perhaps change of color, and of course the triggering of an event or the ability to bind a Command. As of Xamarin Forms 3.4, this is no longer a pain, now you can define an ImageButton like you would define any element in the interface, and use it similarly to how you would use an Image, and make it respond to how a Button would.
Mastering the StackLayout will make your UIs look so much better, and it is quite simple. Here is how.
Let’s imagine that you already have some login functionality in place inside your application so we can focus on the task at hand: implementing biometrics inside the iOS application. Basically either TouchID or FaceID, depending on what is supported by the device (iPhone 5s to iPhone 8 support TouchID and iPhone X, XR, XS and XS Max support FaceID).
Deploying your app to an iOS device can be tricky at times. But later versions of Visual Studio make it a breeze, here is how to do it.
Well, the title sums it up doesn’t it? If you are going to use Xamarin Forms, WPF, or Windows, you need to know what XAML is.
Getting started building your Xamarin apps? This is the template to use when using Windows.
Getting started building your Xamarin apps? This is the template to use when using macOS.
HOW!? How does Xamarin achieve this? Are you lying to me? This isn’t true right? Is it?
Why would it be important to you to learn Xamarin? Here I discuss the benefits and what you can obtain from this tool.
The Xamarin Forms previewer is a great tool that helps you see in real time how your Xamarin apps' interface is going to look like in a real device. But it seems that Microsoft decided in Visual Studio 2017 15.8 to get rid of it, it isn't anywhere to be found! Is it?
As I was working with a ListView in Xamarin Forms I came across a couple of issues, here I explain how I solve some custom renders not being correctly displayed inside a ViewCell, and the NumberOfRowsInSection method throwing an exception when HasUnevenRows is set to true.
In this video, I talk about how you can create a custom renderer to customize the looks of a Progress Bar for your iOS applications built with Xamarin Forms. That includes changing the progress tint color (foreground color) and the height.
Take this complete guide to Xamarin.Forms and learn to create a full Xamarin.Forms app that uses XAML to define the interface, that uses the NavigationPage to navigate between pages, that implements local databases with SQLite, that uses ListView and DataBinding to list elements from the database, that creates a ToolbarItem, and that is tested directly from Visual Studio 2017 into an Android and an iOS simulator.
This is going to be a very quick and straight forward post, but a very useful one I believe. When searching the web for how to implement the new large titles that were introduced with iOS 11 last year when using Xamarin Forms, I found a few different ways how this is supposed to work, only one eventually worked for me.
In the last few posts, I've been introducing the usage of certain interfaces that help use the MVVM pattern in Xamarin Forms applications. You can even find all that code and identify what I did in each post by switching branches in this repository.
In this post, I'll be talking about the ObservableCollection<T>, which isn't an interface, but does implement the INotifyCollectionChanged interface, which behaves similarly to the INotifyProeprtyChanged interface, and helps integrate notifications for when elements are added, deleted or updated within a collection.
In the previous posts, I have been creating a "calculator" using the MVVM architectural pattern, explaining the ICommand and INotifyPropertyChanged interfaces. I suggest you fork the code from this repository and take a look at the branches so you know what we added in each of those posts, or better yet, read through those posts before continuing with this one.
Because in this post we will take a look at the IValueConverter interface, and how it is a key interface that you can use when you have some information on the Model that has to be presented differently in the View. Say a DateTime that instead of displaying "2018-03-21T15:04:30.0000000-06:00" has to be displayed as "two days ago".
I will implement a very easy example that I hope will make it clear how you can use the interface.
In the previous post, we talked about the INotifyPropertyChanged, and I gave a small introduction about the MVVM architectural pattern, and how it will allow you to structure your code in a way that will make it easy to maintain, easy to scale and easy to reuse.
This post will be about the ICommand interface. If you have created Xamarin Forms applications before, this interface will help you replace all the event handlers you have in the code behind for button clicks (and other events) for code that you can now move over to your ViewModel.