Please enable Javascript to correctly display the contents on Dot Net Tricks!

Understanding Xamarin Forms - Build Native Cross Platform Mobile Apps

  Author : Shailendra Chauhan
Posted On : 06 Mar 2017
Total Views : 3,970   
Updated On : 07 Mar 2017

Xamarin Forms is a part of Xamarin family to build truly native apps for iOS, Android & Windows from a single and shared code base using C#. Xamarin.Forms offers the UI controls/views which you can use to develop UI. These UI controls/view at run-time are converted to platform-specific UI controls.

For Example

A Xamarin.Forms Button view will map to an Button on Android, a UIButton on iOS and a Button on Windows Phone or Windows UWP.

Xamarin Forms UI Rendering

Xamarin Forms allows developers to declare the UI using XAML (Extensible Application Markup Language) or C# code. Using Xamarin Forms approach you can develop truely native cross platform mobile apps with shared UI and code behind code using c#.

Xamarin Forms UI

Xamarin Forms Architecture

Xamarin.Forms is an abstraction layer on the top of the Xamarin.iOS and Xamarin.Android to build shared UI using XAML or C# code. It also allows to interact with the platform specific APIs to access mobile native features.

Xamarin Forms Architecture

Environment Setup

Xamarin Forms allows you to develop truely cross platform native apps for android, iOS and windows using C#. A Xamarin forms project for Android, iOS and Windows UWP are based on theirs platform standard project structure. Xamarin forms development you can do using IDEs - Visual Studio for Windows and Xamarin Studio or Visual Studio for Mac.

Xamarin Development with Windows Machine


Visual Studio for Windows need a connection with Mac machine to develop iOS apps.

Xamarin (Xamarin.iOS, Xamarin.Android & Windows) vs. Xamarin Forms

Xamarin vs. Xamarin Forms
Xamarin.iOS, Xamarin.Android & Windows
Xamarin Forms
Use separate UI per platform
Use one UI for all platforms
Use all platforms specific views for each platform
Use basic views, available on all platforms like Button, Textbox etc.
Need to learn all platform specific native UI views
No need to learn all platform specific native UI views
Takes time to develop cross platform mobile app
Faster cross platform mobile app development approach
Supports up to 60% code reuse
Supports up to 100% code reuse
Recommended where custom UI is more important than code sharing
Recommended where code sharing is more important than custom UI
Best for apps which use many platform-specific APIs
Best for apps which use little platform-specific functionality
What do you think?

Thank you for your time, I hope you enjoyed this article and found it useful. Please add your comments and questions below. I would like to have feedback from my blog readers. Your valuable feedback, question, or comments about this article are always welcome.


Shailendra Chauhan
Author, Architect, Corporate Trainer and Microsoft MVP

He is the author of some of most popular e-books which encompass technical Interview on Node.js Interview Questions and Answers, ASP.NET MVC Interview Questions and Answers, AngularJS Interview Questions and Answers and LINQ Interview Questions and AnswersKnow more...

Free Interview Books
14 OCT
Angular2 and Angular4 (Online)
03:00 PM-05:00 PM IST (+5.30GMT)
12 OCT
ASP.NET Core (Online)
09:00 PM - 11:00 PM IST(+5:30 GMT)
10 OCT
Microsoft Azure Infrastructure Solutions (Online)
08:00 AM-09:30 AM IST / 09:30 PM -11:00 PM CST
30 SEP
Angular2 and Angular4 (Classroom)
08:30 AM-11:30 AM IST
20 SEP
MEAN Stack (Online)
07:00 AM-09:00 AM IST
20 SEP
ASP.NET MVC with Angular4 (Online)
9:00PM- 11:00PM IST(+5:30GMT)
16 SEP
Angular2 and Angular4 (Online)
08:00 AM-10:00 AM IST(+5.30 GMT)
22 AUG
ASP.NET Core with Angular4 (Online)
07:00 AM - 9:00 AM IST(+5:30 GMT)