Jumat, 29 Juli 2016

Windows 10 App Development Tutorial - Getting started with UWP app development, beginners guide (C#-Xaml)

Introduction:
This article is only for the people who were really don't know about Windows 10 UWP app development and also who are looking for the answer to "why now days people are already started to learn Windows 10 app development instead of Windows phone 8.1..Windows Phone 7.0?". Also hope you already heard about the most of companies are started to hiring the people who were experienced in Windows 10 UWP development and why?. And some people are having question like "Is it possible to develop UWP with Xamarin Technology?". These all questions can be covered in this article and hope you visited this article means you are showing the interest to learn UWP development:).

Note: This article is only for Windows App developers and not for Windows consumers :P. It would be great and impressive, still you are reading this article with non-technical knowledge :)

Description:
Generally what happens, If we want to learn Windows 10 UWP programming probably we will have below questions in our mind:
  • Why Windows 10 UWP instead of Windows phone 8.1..Windows Phone 7.0?
  • Which programming language, we need to learn for UWP development?
  • What is the IDE for UWP?
  • What are the System Requirements for UWP Development?
  • Where we will find resource to learn UWP?
  • How to build first Windows 10 UWP App?
  • How to test first Windows 10 UWP App?
  • How to get help, if we got any issue in UWP app development?
  • How to submit UWP app to the Windows Store?
  • What is the career future, if we learn UWP? 
  • Can we develop UWP with Xamarin.Forms?
  • If I missed any question which is in your mind, please mention in comment section and we will discuss about it :)
Mostly we will get answer for above questions, if we search them in Bing/Google search engine, But let us see our own words to answer them from this article with step by step.

I don't want to answer you about "Why we need to build Mobile App ?" as you are MAD (Mobile App Developer) :). Also nowadays if you ask this question even non-technical guy also will answer it because of most of people are using smartphone applications, and people are looking for easiest way to use application instead of browsing website url :)

Let's take our first question.
1. Why Windows 10 UWP instead of Windows phone 8.1..Windows Phone 7.0?
Actually It has big story behind Windows 10 development release by Microsft. And people are easily answering like "UWP is a single development platform where we can develop single app with single app package that can run across all Microsoft platforms (Mobile,Desktop,Xbox,Surface Hub, Holographic, IOT..etc).


Let's see the history of Universal Windows Platform (UWP) Development.
  • At very first time Microsoft was started smart phone programming with Windows Phone 7.0 as the replacement successor to Windows Mobile in year of 2010 November. Initially windows phone smartphone programming was started on Silverlight framework.
  • if we create WP7.0/8.0 app project on Silverlight framework and build the app, we will have build package file with .xap extension that can run only on WP7.0/WP8.0 OS smartphone devices and app will not support windows desktop or surface.
  • Other side means (Desktop, Surface, Table..etc) Windows 7.0/8.0 we called it was WinRT framework, so if we create Windows 7.0/8.0 project on WinRT framework and build the app, we will have build package file with .appx extension that can run only on Windows 7.0/8.0 OS machines and not in smartphone devices. 
  • So it is complicated for the Windows developers and they need to create two separate development apps for both smartphones & Desktop. After that Microsoft was started to develop one single development environment for providing common API's for developers to develop both smartphone apps & Desktop apps at a time. 
  • However at the time of Windows Phone 8.1 release, Microsoft was taken one step forward and released the WP8.1 app development that can support on both Silverlight & WinRT frameworks app.
  • So at any time if we create windows phone apps on Silverlight framework, app will run only on windows phone OS smartphones.
  • From 8.1 OS if developer starting to build app on WinRT framework, he can able to create same app for both phone & surface using single Universal App Project. but we need to create two different app packages (.APPX) for windows phone & Windows.
  • After that Microsoft was released Windows 10 UWP(Universal Windows Platform). And now no more than one app package and we can create single app project with only one app package that can run across all Microsoft platforms (Mobile,Desktop,Xbox,Surface Hub, Holographic, IOT..etc)
Hope you enjoyed to read above history, and let's take second question:

2. Which programming language, we need to learn for UWP development?
There are two ways to develop Windows 10 UWP apps:
  • Native Approach: using C# (Logic) with Xaml (UI design) on WinRT framework.
  • Cross platform Approach: We can create UWP app with Xamarin cross platform development with same C# & Xaml programming. And also we can use other languages HTML5 , JavaScript and CSS (Using cross platform frameworks like Cordova, phonegap..etc) to develop UWP apps.
Note: Honestly i don't want to recommend you for other language to develop native windows apps, and it is better to choose C# (Logic) with Xaml (UI design).

3. What is the IDE for UWP?
We need to use Microsoft Visual Studio 2015 Update 1 or Later IDE to develop UWP apps. So get step by step help to install Windows 10 SDK from here.

4What are the System Requirements for UWP Development?
  • To develop UWP app, we need to install latest Windows 10 SDK that works best on the Windows 10 operating system. And fortunately it is also supported on: Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows Server 2008 R2, but not all tools are supported on these operating systems.
  • We no longer need a developer license with Windows 10. But we must Enable Developer Mode to your device for development.
5. Where we will find resource to learn UWP?
If you’re new to the Windows 10 UWP, In this article I will share some great learning resources that helped you get your foot on the ladder. Before going to start Windows 10 UWP, and if you are very new to Windows App Development, you sould have some basic knowledge on Xaml & C# Programming.
Learning XAML
XAML is fundamental to UWP Development, without understanding it you can not develop UWP. So below are some great places to learn what XAML is, how/why it’s used, and it’s syntax:
Learning C#
This tutorials will teach you basic C# programming and will also take you through various advanced concepts related to C# programming language.
This tutorials will teach you basic UWP programming and will also take you through various advanced concepts related to UWP.
6. How to build first Windows 10 UWP App?
It is very easy step to create UWP project. So open your latest VS 2015 IDE from start menu.
  • Launch Visual Studio 2015
  • On the File menu, select New > Project.
  • The New Project dialog appears. The left pane of the dialog lets you select the type of templates to display.In the left pane, expand Installed > Templates Visual C# > Windows, then pick the Universal template group. The dialog's center pane displays a list of project templates for Universal Windows Platform (UWP) apps.
  • In the center pane, select the Blank App (Universal Windows) template.The Blank App template creates a minimal UWP app that compiles and runs, but contains no user-interface controls or data. In the Name text box, type "Hello World".Click OK to create the project. You need to add controls to the app and you can also get full help to create new project from this tutorial
7. How to test first Windows 10 UWP App?
Now its time to test UWP App, In addition to the option to Debug on a desktop device, Visual Studio provides options for deploying and debugging your app on a physical mobile device connected to the computer, or on a mobile device emulator. You can choose among emulators for devices with different memory and display configurations like below
Note: 
1. It's a good idea to test your app on a device with a small screen and limited memory, so use the Emulator 10.0.10240.0 WVGA 4 inch 512MB option.
2. If you want to test our app in physical device, you must Register your Windows Phone device for development.
3. If you already have .APPx file, you can deploy it from WinAppDeployCmd.exe tool
After selecting emulator/device, From the Debug menu, click Start Debugging or Press F5. Then we can found below screen on emulator/device:

8. How to get help, if we got any issue in UWP app development?
Although If you have any technical issue during UWP app development, you can find lots of help and information at the following forums communities:
9. How to submit UWP app to the Windows Store?
In order to publish UWP application to windows store, we should have Windows store developer account. And there are two kinds of accounts: a Individual account which will cost you 19.00 USD and an Company account which will cost you 99.00 USD. So get help to create developer account from here and get list of app-submission markets from here. After getting developer account, we need to submit app to the store and get step by step help to submit app from here. So after that the validation process will start with very strict and take you about maximum one day . if your app is rejected, you will get an error report about what you have to change in your app to pass certification and visible on store. It don't have malwares in the Windows store marketplace because of it's a trusted store.

10. What is the career future, if we learn UWP?
This is big question, was raised in UWP developers. And the people got some rumours about "Microsoft will stop to work on smart phones development". No I am completely disagree with this. People who are working on UWP, they are almost developing the app that can support for all Microsoft devices with single project and it means people will have good future and more opportunities. In rare case if you thought no future, at-least you will get good experience on C#.net & Xaml programming and so what else you need my dear :). Now days if you know C#.net & Xaml and you will almost good at your career, because we have so many options like big advantage is we can easily learn Xamarin cross platform development technology which is running on same C# & Xaml programming :), also we can develop Unity 3D gaming apps with C#. 

11. Can we develop UWP with Xamarin.Forms?
Yes, as we just had discussion about it in previous question. But one concern is our machine should have Windows 10 OS and should install latest VS 2015 IDE. If we create Xamarin.Forms Project with VS 2015, Then created project will have bellow structure:
  • Shared: Shared Project containing the code common to all projects and it will be either PCL or Shared Project.
  • AppAndroid: Xamarin.Android application project.
  • AppiOS: Xamarin.iOS application project.
  • AppWinPhone: Windows Phone application project.
  • AppWindows: Windows application project.
  • AppUWP: Universal Windows Platform application project.
Note: We can't develop Windows Phone, Windows & UWP apps with Xamarin Studio. So we must have Visual Studio IDE to build windows apps with Xamarin Technology.

And we are very lucky people as we are developing UWP native app using C#.net & Xaml and it means we were already experienced in C#& Xaml. So we can easily learn Xamarin Technology to build single code base app that can support for all three major mobile platforms Windows, Android & iOS :)

If you want to looking for UWP sample, you can directly download below source code.
Calendar Control Sample
FeedBack Note:
Please share your thoughts,what you think about this post,Is this post really helpful for you?I always welcome if you drop comments on this post and it would be impressive.

Tweet me always at @Subramanyam_B
Have a nice day by Subramanyam Raju :)



Senin, 25 Juli 2016

7 Cara Terbaik Agar Blog Efektif Menghasilkan Uang

7 Cara Terbaik Agar Blog Efektif Menghasilkan Uang


Cara Menguangkan Blog Anda dan Mulai membuat uang online nyata?

Kita semua tahu bahwa ada begitu banyak cara untuk menghasilkan uang dari blogging, tetapi kebanyakan dari kita yang awan dan newbie di dunia blogging tidak tahu cara yang lebih efisien agar blog yang kita kelola mampu menghasilkan uang.

Jadi saya tidak akan berbagi tips di sini, dan  saya akan memberikan beberapa cara yang lebih efisien untuk membuat uang dari blogging. Mari kita ke ikuti tips dibawah ini.
Note :Tidak ada satupun keberhasilan tanpa ada perjuangan,belajar mencoba dan mencoba dan kerja keras, jika Blogging Anda jadikan hobby ( sampingan saja ) jadikan hobby itu menghasilkan uang.

1. Google AdSense

Google AdSense masih merupakan cara paling efektif untuk menguangkan blog. Tetapi dapat memberikan Anda banyak penghasilan uang yang layak setelah blog Anda memiliki lalu lintas besar.
Katakanlah Anda mendapatkan 1000 kunjungan per hari, Anda dapat dengan mudah mengharapkan 200 $ 300 $ per bulan dengan memanfaatkan lalu lintas blog Anda. Tempatkan iklan GA ( Google Adsense ) Anda secara bijaksana ( tepat ) untuk mendapatkan lebih banyak klik. Tentunya lebih banyak klik = lebih banyak uang!

Catatan: Jika Anda tidak memiliki akun Google Adsense karena tidak disetujui 9 approve , maka Anda dapat mencoba Infolinks karena merupakan alternatif terbaik selain Google Adsense.




 

2. Banner ads
Jika Anda tidak tertarik menempatkan iklan Google AdSense di blog Anda, Dengan menampilkan iklan banner adalah cara terbaik untuk membuat lebih banyak uang. Gunakan jasa jual beli iklan dan memasukkan rincian iklan di blog Anda. Jika blog Anda menerima lalu lintas potensial, Anda akan mendapatkan banyak kesempatan dari orang lain untuk menempatkan iklan mereka di Blog Anda. Anda dapat menghubungi beberapa merek besar di niche Anda untuk mendapatkan iklan langsung. Ini adalah salah satu metode yang menguntungkan serta efektif untuk mendapatkan uang dari blogging.

3. Product reviews ( Ulasan produk )

Kita banyak tahu beberapa rekan rekan blogger yang mampu membuat $ 100 sampai $ 500 hanya dengan menerbitkan produk 2 sampai 3 ulasan sebulan di blog mereka. Posting ( Product reviews ) penjelasan detail suatu produk adalah cara yang efektif untuk membuat uang dari sebuah situs. Jika Blog Anda memiliki pembaca setia maka ulasan ulasan produk yang Anda sajikan akan mampu mendatangkan uang lebih ( ulasan produk berbahasa inggris akan jauh lebih baik ). Jika Anda tidak bisa berbahasa Inggris gunakan saja google translate, tidak masalah. Anda dapat biaya $ 100 sampai $ 500 per ulasan tergantung pada Blog Anda.

4. Blog services ( Layanan Blog )

Jika Anda seorang pemula di dunia blogging dan memiliki gairah terhadap dunia sales marketing, ini adalah metode yang tepat untuk Anda. Anda dapat menjual jasa Anda menulis artikel, layanan pembuatan desain logo, pembuatan tema, membuat desain template atau layanan plugin pada blog Anda agar menhasilkan uang.

Hal yang baik tentang model monetisasi ini, Anda tidak perlu lalu lintas besar untuk membuat lebih banyak uang. Tapi Anda memberikan paparan kualitas dari pengunjung untuk mengambil layanan Anda. Semakin banyak klien Anda maka Anda akan dapat menghasilkan uang setiap bulannya.

5. Affiliate marketing  ( Afiliasi pemasaran )

Ingin membuat uang bahkan saat Anda tidur? Afiliasi pemasaran adalah pilihan yang tepat untuk Anda kemudian. Tapi Anda harus memiliki beberapa keterampilan untuk menjual produk orang lain di situs Anda. Ingat tidak ada yang suka membeli barang dari orang asing. Jadi menurut saya jika Anda memiliki daftar email dari orang lapar Anda dapat membuat banyak uang dari afiliasi pemasaran. Kesabaran adalah kunci nyata dalam membuat lebih banyak uang dari afiliasi pemasaran.

6. Menjual produk Anda sendiri ( Istilah kerennya Sell your own products )

Jika tidak ada dari kita yang berhasil membuat uang online, jual produk Anda sendiri. Maksudnya jual produk dari hasil karya atau jual keahlian ( jasa/ketrampilan ) yang Anda miliki. Seperti menjual eBook tentang tutorial tutorial pemecahan masalah IT,Pertanian,Peternakan,Budidaya, Produk informasi, plugin, tema dll Ini benar-benar tergantung pada kemampuan dan skill Anda, ciptakan kwalitas layanan dan informasi maka uang akan lebih mudah masuk. Apa keahlian Anda, jangan ragu untuk menulis artikel,tutorial, informasi tentang wawasan yang Anda miliki dan mulailah meluncurkan produk Anda setelah menganalisis kemampuan Anda untuk memaksimalkan pendapatan Anda.

7. Membangun Daftar Email

Salah satu cara terbaik membuat uang online adalah membangun sebuah daftar email. Daftar email adalah cara untuk membuat pendapatan yang layak dari usaha blogging Anda. Uang itu dalam daftar email. Jika Anda tidak membangun sebuah daftar email, Anda pasti kehilangan uang dari blogging yang sedang anda geluti. Mulai membangun sebuah daftar email dari hari pertama dari karir blogging Anda.

Jika Anda bertanya-tanya bagaimana untuk mendapatkan pelanggan email lebih banyak ? Disini saya akan membahas cara-cara efektif untuk mendapatkan daftar email lebih banyak :

1. Mendorong Blog lebih banyak lalu lintas:Tidak peduli seberapa baik tawaran Anda, Anda tidak akan mendapatkan pelanggan email lebih tanpa mengarahkan kualitas lalu lintas ke Blog Anda. Semakin banyak lalu lintas ,maka Anda memiliki lebih cepat daftar email, memang sesederhana itu. Gunakan posting tamu ( blog walking ), komentar blog, iklan PPC dll untuk mengarahkan lalu lintas ke blog Anda atau halaman arahan.

2. Tawarkan freebie: Jika Anda ingin cepat membangun sebuah daftar email, berikan sesuatu secara gratis. pembaca online tidak mendaftar ke situs Anda hanya karena Anda sedang membangun daftar email ( contoh : Feedburner ). Pengunjung Blog hanya ingin alasan untuk berlangganan newsletter karena tertarik artikel Anda dan dianggap informatif. Jadi buatlah sesuatu yang informatif dan berikan semuanya secara gratis kepada pengunjung Blog Anda. Mereka tertarik dan kembali lagi mengunjungi Blog Anda maka disitulah awal Anda membuat rencana monetesisasi Blog secara efektif.

3. Gunakan autoresponder terbaik: Banyak sekali rekan rekan blogging menggunakan dan merekomendasikan GetResponse. Jika anda serius tentang membangun sebuah daftar email, menggunakan layanan seperti GetResponse, aweber, Mad Mimi dll Karena daftar email adalah bisnis dan merupakan kebutuhan bisnis investasi. Ingat lho ya daftar Email yang Anda peroleh adalah bekal investasi Anda, tinggal bagaimana Anda mengoptimalkannya secara positif.

4. Gunakan halaman arahan ( redirect links ): halaman Blog adalah gangguan besar pada umumnya ( yang umum terdapat pada kolom komentar blog ). Jika Anda ingin lebih banyak konversi pada daftar email yang Anda miliki, coba gunakan halaman arahan. halaman arahan, ini sedikit menganggu pengguna namun masih dalam batas wajar jika tidak berlebihan. Anda dapat menggunakan alat-alat seperti OptimizePress, Thrive Landing Pages dll untuk membangun halaman arahan.

5. Gunakan panggilan efektif untuk tindakan: Jangan menggunakan kata-kata seperti "berlangganan" "mendapatkan update gratis" dsb di situs Anda. Orang-orang umumnya muak melihat begituan. Gunakan panggilan efektif untuk tindakan seperti "Dapatkan gratis Anda sekarang" "mengunduh laporan" dll untuk dengan mudah meyakinkan pengunjung Anda untuk berlangganan artikel informatif Anda. Jadilah yang kreatif sekaligus menciptakan panggilan pengunjung Blog lalu mereka bertindak ( maksudnya : berlangganan artikel Anda ).

6. Gunakan situs media sosial: Media sosial adalah cara ampuh untuk mendapatkan lebih banyak lead email. Sosial media tumbuh lebih besar dan lebih besar. Jika Anda tidak terlibat dengan pengunjung lain di media sosial, Anda pasti kehilangan banyak pengunjung ke situs Anda. Buat Facebook fan pages, aktif di twitter dan berhubungan dengan orang lain di G + untuk menumbuhkan jaringan Anda.

7. Pro tip untuk membuat uang online: Sebelum menggunakan model monetisasi dari atas, pastikan untuk menguji setiap model satu demi satu. Jangan mencoba untuk menguangkan blog Anda menggunakan semua metode  online diatas ( kita tidak bisa serakah ). Dan Anda tidak akan mendapat penghasilan sepeser pun jika Anda ter-fokus pada satu metode monetisasi, tanpa mencoba metode lain yang mungkin cocok dengan keahlian Anda di bidang tertentu, dan itu yang mampu menghasilkan uang.

Jadi apa pendapat tentang memonetisasi blog atau website pada tahun 2016 dan seterusnya? Apapun bentuk metodenya jika itu terbukti efektif dan mampu membantu yang lain untuk membuat uang online? Silakan berbagi pengalaman Anda pada kolom  komentar dibawah ini.
Terima Kasih..

Minggu, 17 Juli 2016

Top 50 Xamarin Cross Platform Development Interview questions (C# - Xaml)

Introduction:
It is time to learn xamarin cross platform development and people are already started in so many organizations, because of we can deliver native iOS, Android, and Windows apps using existing skills, teams, and code(C#, xaml ) with free of cost. Many company's are started hiring the Xamarin developers, and if you are good at xamarin, they are ready to give bigger packages for you as much as possible. If you are looking for Xamarin developer position in new company and you may need to face interview questions on Xamarin Technology. Here I am going to explain you most common interview questions with answers and also please correct me if any wrong content found in this article. Also pleases note that for accuracy purpose I visited Xamarin official website and googling as well to adapted some content.

1. What is the difference between Native App and Cross Platform APP?
  • Native App: If we want to develop native apps, we need to choose the specific native language (C#, Objective-C, Swift, and Java) for developing specific native app for Windows, Android, iOS.
  • Cross Platform App: This is the way to develop all three mobile apps using single code base wrapped in a native application layer, but it always requires customization of interfaces to native languages.
2. What is Xamarin?
It is cross platform development technology, where we can build native user interfaces for iOS, Android and Windows Phone using single codebase with C#.

3. Xamarin history?
  • Xamarin is a Microsoft-owned San Francisco, California based software company founded in May 2011 by the engineers that created Mono, Mono for Android and MonoTouch .
  • Novell had granted a perpetual license for Mono on july 2011 for MONO 
  • On May 16, 2011: Miguel de Icaza announced on his blog that Mono would be developed and supported by Xamarin,
  • December 2012, Xamarin released Xamarin.Mac which allows developers to build C#-based applications for the Apple OS X operating system and package them for publishing via the Apple App Store.
  • Xamarin 2.0 was released in February 2013 Xamarin.Android and Xamarin.iOS that make it possible to do native Android, iOS and Windows development in C#, with either Visual Studio or Xamarin Studio.
  • Xamarin.forms: Introduced in Xamarin 3 on May 28, 2014 and allows one to use portable controls subsets that are mapped to native controls of Android, iOS and Windows Phone.
  • On February 24, 2016: Microsoft announced it signed a definitive agreement to acquire Xamarin
  • On March 30, 2016: Microsoft acquired the xamarin. And made it for all with free of cost.
4. Mono vs. Monodevelop vs Xamarin
Mono: It is a framework and an open source implementation of Microsoft’s .NET Framework based on the open standards of European Computer Manufacturer's Association (ECMA) for the C# language and the Common Language Runtime. And Mono allows C# developers to write cross platform code targeting Windows, Mac OS X, Linux, Android, and iOS. 
MonoDevelop: It is an open source integrated development environment (IDE) for Linux, OS X, and Windows. Its primary focus is development of projects that use Mono and .NET frameworks.
Xamarin: a subsidiary of Microsoft - is a company founded by the engineers who created Mono. Xamarin is the primary maintainer and commercial sponsor of Mono. It provides professional developer tools that make cross platform code easier to author, test, and maintain.

5. What are the programming languages that support Xamarin Development?
  • Xamarin is unique in this space by offering a single language – C#, class library, and runtime that works across all three mobile platforms of iOS, Android, and Windows Phone (Windows Phone’s native language is already C#)
  • Also offers xaml support for creating user interface.
6. Why Xaml in Xamarin.Forms?
  • XAML(Extensible Application Markup Language) allows developers to define user interfaces in Xamarin.Forms applications using markup rather than code.
  • XAML defines the visual appearance of a UI, and an associated code-behind file defines the logic. The UI design can be adjusted without necessarily making changes to the logic in code-behind. XAML in this role simplifies the workflow between individuals who might have a primary visual design responsibility and individuals who are responsible for app logic and information design.
7. What are disadvantage of Xaml in Xamarin.Forms?
  • XAML cannot contain code. All event handlers must be defined in a code file.
  • XAML cannot contain loops for repetitive processing. (However,ListView —can generate multiple children based on the objects in its ItemsSource collection.)
  • XAML cannot contain conditional processing (However, a data-binding can reference a code-based binding converter that effectively allows some conditional processing.)
  • XAML generally cannot instantiate classes that do not define a parameterless constructor. (However there is sometimes a way around this restriction.)
  • XAML generally cannot call methods. (Again, this restriction can sometimes be overcome.)
8. What are the IDE's we can use for Xamarin App Development?
Xamarin Studio: This is Xamarin’s C# developer environment that runs on both Windows and Mac. Xamarin Studio has many of the features of Microsoft’s Visual Studio and uses exactly the same formats as Visual Studio: solutions (.sln) and C# projects (.csproj).
Visual Studio: Xamarin offers a Visual Studio extension/plugin for visual studio 2012, visual studio 2013 update 1. And now Xamarin development is directly available from Visual studio 2015.

9. What was the major advantage of Xamarin Development?
  • We can deliver native iOS, Android, and Windows apps using existing skills, teams, and code(C#, xaml )
  • We can take full advantage of Native API’s with Xamarin Technology . And Xamarin.Forms elements map to native controls and behaviors
  • Xamarin Component Store allows adding high-quality components to your app directly from your IDE, including controls, web service APIs and more.
  • PCL/ Shared projects makes very easy for developers to share the same code base across different projects.
10. What are difference between Xamarin Studio and Visual Studio?
Notes:
  • We can't create Windows Phone, Windows & UWP from Xamarin Studio.
  • Xamarin Studio in Mac can allows you to develop iOS & Android apps.
  • Xmarin Studio in Windows can allows you to develop Android apps only. And it encourage Windows users to move to Visual Studio.
  • Xamarin for Visual Studio supports any VS 2015, VS 2013 Update 2 and Visual Studio 2012 with non-Express editions. And visual studio can't install on Mac machine.
  • To test iOS app on Windows OS with VS, must be a Mac computer accessible on same network.
  • To develop Xamarin.Forms apps for the Universal Windows Platform (UWP) requires Windows 10 with Visual Studio 2015
11. What are the life cycle's of Xamarin.forms app development?
Life-Cycle means a specific sequence of the application from start to finish of the application. So there are three important states in the life cycle of a Xamarin app development.
OnStart: Called when the application starts.
OnSleep: Called each time the application goes to the background.
OnResume: Called when the application is resumed, after being sent to the background.
Note:
There is no method for application termination. Under normal circumstances (ie. not a crash) application termination will happen fom the OnSleep state, without any additional notifications to your code.

12.How many ways we can create Xamarin applications?
There are two ways to deliver native iOS, Android, and Windows apps using Xamarin Technology
Traditional Xamarin approach: This approach can provide direct access to platform-specific API’s. And we can create platform specific apps such as using Xamarin.iOS for iOS applications, using Xamarin.Android we can create Android applications.
Xamarin.forms: This architecture is the same as that of traditional cross-platform apps. The most used method is to implement Portable Libraries or Shared Projects to save the shared code, and then create specific applications for each platform that will consume this shared code. 

13. When to use Xamarin.Forms vs Xamarin Native?
Xamarin.Forms:
  • Apps that require little platform-specific functionality.
  • Apps where code sharing is more important than custom UI.
Xamarin.IOS,Xamarin.Android:
  • Apps that require specialized interactions.
  • Apps with highly polished design.
  • Apps that use many platform-specific APIs.
  • Apps where custom UI is more important than code sharing.
14. What are different extension output files generated from xamarin.forms?
If we run the Xamarin app, it can generate following application packages for different platforms
.xap/.Appx for windows phone 8, Windows, UWP
.ipa file for IOS
.apk file for Android

15. What are the different application package running modes in Xamarin?
When you compile an application, you usually choose between below two modes:
Debug: Debug mode pads the executable file with extra information used for debugging purpose. After your application is bug-free and feature-complete, there's no longer any need to keep the debug information.
Release: Compiling in Release mode gives you a more compact (and even slightly faster) executable that doesn't include unnecessary internal debugging symbols
Note: Packages should be in release mode, which would be provided to an App store.

16. How does Xamarin.Android(Mono for Android) work?
On Android, Xamarin ships a fully functional implementation of the .NET runtime, called Mono, bundled with your app so that your code executes with all of the power of C# and .NET, including JIT-compilation, memory management, reflection, and the .NET base class libraries. Developers can use any native features by interacting with .NET class libraries that provide one-to-one mappings to all of the native APIs on Android.

17. What is the difference between Xaml & axml in Xamarin Technology?
  • AXML and XAML are two different XML specifications.
  • AXML is just supported/available for Xamarin.Android.
  • XAML is the way Xamarin Forms could standardize Cross Platform UI based on XML specification.
  • XAML is the way Xamarin Forms could standardize Cross Platform UI based on XML specification.
  • If you are using native Xamarin Android you will do UI using axml, if using Forms then using XAML.
18. How does Xamarin.IOS work?
On iOS, Xamarin uses Mono, a fully functional implementation of the .NET runtime, to fully compile your app into a native ARM executable ahead of time (AOT) so that your code executes with all of the power of C# and .NET, including memory management, reflection, and the .NET base class libraries. Developers can use any native features by interacting with .NET class libraries that provide one-to-one mappings to all of the native APIs on iOS, while complying with Apple's security restrictions which prevent execution of dynamically generated code on device.

19. What is the project structure of Xamarin.Forms?
If we create App with xamarin.forms project using xamarin studio or visual studio. Then created project will have bellow structure:
  • Shared: Shared Project containing the code common to all projects and it will be either PCL or Shared Project.
  • AppAndroid: Xamarin.Android application project.
  • AppiOS: Xamarin.iOS application project.
  • AppWinPhone: Windows Phone application project.
  • AppWindows: Windows application project.
  • AppUWP: Universal Windows Platform application project.
20. What are the different code sharing techniques in xamarin.forms?
There are two alternative methods for sharing code between cross-platform applications:
  • Portable Libraries(PCL)
  • Shared Projects
The goal of a code-sharing strategy is to support the architecture, where a single codebase can be utilized by multiple platforms.

21. Difference between Portable Class Library (PCL) & Shared Projects?
Portable Class Library (PCL):

- Produce libraries that can be shared across multiple platform.
- Targeting specific platform includes interfaces
- Refactoring operations always update.
 Shared Projects:

- Shared code can be branched based on the platform using compiler directives( eg. using #if __ANDROID__, #if __IOS__, #if WINDOWS_PHONE_APP, #if WINDOWS_APP..etc)
- No output assembly.
- Refactoring operations ,not update automatically.

22. What does Pages in Xamarin.Forms?
The Page class is a visual element that occupies most or all of the screen and contains a single child. And pages in xamarin.forms are directly mapped to like below:
  • In iOS  it is a View Controller
  • In Windows Phone it is a Page.
  • In Android it is a Activity.
23. What are the different kinds of Pages in Xamarin.Forms?
Fortunately Xamarin.Forms support multiple page representations, And every representation is having its own purpose like below:
  • ContentPage: A Page that displays a single View, often a container such as a StackLayout or a ScrollView.
  • MasterDetailPage: A Page that manages two panes of information.
  • NavigationPage: A Page that manages the navigation and user-experience of a stack of other pages.
  • TabbedPage: A Page that allows navigation between children pages, using tabs.
  • TemplatedPage: A Page that displays full-screen content with a control template, and the base class for ContentPage.
  • CarouselPage: A Page allowing swipe gestures between subpages, like a gallery.
24. What are the layout controls available in Xamarin.Forms?
Layout is the process of sizing and positioning child elements in UI.
  • ContentPresenter: A layout manager for templated views. Used within a ControlTemplate to mark where the content to be presented appears.
  • ContentView: An element with a single content. ContentView has very little use of its own. Its purpose is to serve as a base class for user-defined compound views.
  • Frame: An element containing a single child, with some framing options. Frame have a default Xamarin.Forms.Layout.Padding of 20.
  • ScrollView: An element capable of scrolling if it's Content requires.
  • TemplatedView: An element that displays content with a control template, and the base class for ContentView.
  • AbsoluteLayout: Positions child elements at absolute requested positions. User assigned anchors and bounds defines the position and size of the control.
  • Grid: A layout containing views arranged in rows and columns.
  • RelativeLayout: A Layout that uses Constraints to layout its children.
  • StackLayout: A Layout that positions child elements in a single line which can be oriented vertically or horizontally. This layout will set the child bounds automatically during a layout cycle. User assigned bounds will be overwritten and thus should not be set on a child element by the user.
25. What is Views?
Views are commonly known as controls of widgets. And they can refer to visual objects such as Label, Button, Entry, Image, BoxView, ListView, TableView..etc. All UI elements are typically are sub-classes of View.

26. What is is the difference between ListView & TableView?
  • The ListView and TableView controls are so similar, you can think of them as a single control. The major difference between the two is the manner in which they lay out their items, and it’s easy to change the layout so each control emulates the other.
  • The ListView control displays its data stacked vertically, much like a standard listbox. Use this control to display an ordered list of data, especially long lists that require scrolling like a list of email messages, a list of contacts, or search results.
  • The TableView control displays its data stacked horizontally in rows (although you can alter this behavior and have it displayed in columns first, as well). You use this control when you need more space for rich visualization of each item to be displayed.
  • One of the big differences is ListView provides you a ItemsSource and a Itemtemplate and TableView does not. So items must be added as children manually.
27. How to draw rectangle in Xamarin.Forms?
BoxView is used to draw a solid colored rectangle. So below source code can create Accent colored rectanlge with width ->200 & Height->100
  1. <BoxView Color="Accent"  WidthRequest ="200"  HeightRequest = "100"/>  

28. What is the difference between Editor & Entry?
Both views are helpful for user to enter text, but there is a small difference is Entry only has one line, whereas a Editor usually has multiple lines that allows user to press ENTER.

29. What is Cell in Xamarin.Forms?
Simple it is not a visual element, but it just describes a template for creating a visual element. And one important note is that Cells are elements designed to be added to ListView or TableView controls.

30. What is difference between Entry and EntryCell in Xamarin.Forms?
  • Entry is a visual element, where user can enter single line text. 
  • EntryCell is not visual element, it is subtype of Cell and it describes a template for label and a single line text entry field. It is normally for use in a ListView or TableView.
31. What is difference between Margin & Padding property?

  • Margin is applied to the outside of you element hence effecting how far your element is away from other elements.
  • Padding is applied to the inside of your element hence effecting how far your element's content is away from the border.
32. How to display alert in Xamarin.Forms?
It is very common UI task is displaying an alert or asking a user to make a choice. So to display alert in Xamarin.Forms, we can use the DisplayAlert method on any Page like below:
  1. DisplayAlert ("Alert""You have been alerted""OK");  

33. What is difference between DisplayAlert and DisplayActionSheet?
  • Xamarin.Forms has two methods on the Page class for interacting with the user via a pop-up: DisplayAlert and DisplayActionSheet. They are rendered with appropriate native controls on each platform.
  • DisplayAlert presents an alert dialog to the application user with a single cancel, and it does not having importance to collect information from the user.      public Task DisplayAlert (String title, String message, String cancel
  • DisplayActionSheet displays a native platform action sheet, allowing the application user to choose from several buttons. Example: await DisplayActionSheet ("ActionSheet: SavePhoto?""Cancel""Delete""Photo Roll""Email");  
34. Why we need write platform specific code in Xamarin Forms?
Xamarin Forms can almost provides 90-95% of share code for all three mobile platform projects (Windows, Android, iOS). However, there are going to be cases where you need to get at something that really isn’t generic, something that’s done a little differently on each platform. That could be something relatively significant (like a custom “renderer”) or something as simple knowing the platform-specific path for local storage, geolocation,text-to-speech..etc.

35. How to write platform specific code in PCL project of Xamarin.Forms?
We already know compiler directives concept (#ifdef option) is not available in PCL . But in alternative we have majorly there are three ways to create platform specific code in PCL project.
  • DependencyService: It can allows apps to call into platform-specific functionality from shared code. This functionality enables Xamarin.Forms apps to do anything that a native app can do.
  • Device: It is a class contains a number of properties and methods to help developers customize layout and functionality on a per-platform basis. (Ex:Device.OnPlatform, Device.OS, Device.Idiom..etc)
  • Custom Renderers: By default each page, layout, and control in xamarin.forms are rendered differently on each platform, using a Renderer class that in turn creates a native control, arranges it on the screen, and adds the behavior specified in the shared code. But using Custom renderers, developers can be used for small styling changes or sophisticated platform-specific layout and behavior customization.
36. How does DependencyService work in Xamarin.Forms?
DependencyService can useful for accessing native mobile features (local storage, geolocation,text-to-speech..etc). But we need to follow below four steps to use DependencyService:
  • Interface: The required functionality is defined by an interface in shared code.
  • Implementation Per Platform: Classes that implement the interface must be added to each platform project.
  • Registration: Each implementing class must be registered with DependencyService via a metadata attribute. Registration enables DependencyService to find the implementing class and supply it in place of the interface at run time.
  • Call to DependencyService: Shared code needs to explicitly call DependencyService to ask for implementations of the interface.
37. How does Custom Renderers work in Xamarin.Forms?
Custom Renderers can be used for small styling changes or sophisticated platform-specific layout and behavior customization. But we need to follow below three steps:
  • Create a subclass of the renderer class that renders the native control.
  • Override the method that renders the native control and write logic to customize the control. Often, the OnElementChanged method is used to render the native control, which is called when the corresponding Xamarin.Forms control is created.
  • Add an ExportRenderer attribute to the custom renderer class to specify that it will be used to render the Xamarin.Forms control. This attribute is used to register the custom renderer with Xamarin.Forms.
Below image represents steps for Customizing an Entry with Custom Renderer
38. How to use Device.OnPlatform in xaml and C#?
Device.OnPlatform is a generic method that has three optional parameters: iOS, Android, and WinPhone. It can be used to provide platform-specific values. For example if we want to set different padding values for different platform we can use like below:
In Xaml:

  1. <ContentPage.Padding> 
  2. <OnPlatform x:TypeArguments="Thickness" iOS="0, 20, 0, 0" Android="0" WinPhone="0"/> //left and right padding: 0; top padding: 20 (only on iOS)  
  3. </ContentPage.Padding>  
In C#:
On page constructor
  1. Padding = new Thickness (0, Device.OnPlatform(20,0,0), 0, 0);  //left and right padding: 0; top padding: 20 (only on iOS)  

39. What are list of compiler directives available in Shared Asset Project(SAP) ?
Compiler directives are only available in Shared projects and not in PCL. And these are useful to write platform specific code using C# preprocessor directives #if, #elif, #else, and #endif with conditional-compilation symbols defined for the three platforms, as list of compiler directives shown below:
  • __IOS__ for iOS
  • __ANDROID__ for Android
  • WINDOWS_UWP for the Universal Windows Platform
  • WINDOWS_APP for Windows 8.1
  • WINDOWS_PHONE_APP for Windows Phone 8.1
For example, to get operating system in windows phone 
  1. #if  WINDOWS_PHONE_APP  
  2.   
  3. EasClientDeviceInformation devInfo = new EasClientDeviceInformation(); 
  4. versionLabel.Text = devInfo.OperatingSystem; //To get device operating system.
  5.  
  6. #endif
40. What is Data Binding in Xamarin?
  • Data binding is a technique to automatically synchronize a user interface with its data source. When a binding is established and the data or your business model changes, then it reflects the updates automatically to the UI elements and vice versa. 
  • Data binding connects two objects, called the source and the target. The source object provides the data. The target object, which must be a bindable property, will consume (and often display) data from the source object. It is also possible to bind, not to a standard data source, but to another element on the page.
41. What are different type of Data Binding modes in Xamarin?
Data binding connects two objects, called the source and the target. So the relationship between target and source is defined by members of the BindingMode enumeration and there is four kinds of binding modes are available in Xamarin.Forms.
  • Default (Optional & not considered)
  • OneWay — changes in the source affect the target (normal).
  • OneWayToSource — changes in the target affect the source.
  • TwoWay — changes in the source and target affect each other.
Note: If you don’t specify anything, the default binding mode is OneWay

42. What are the different scenarios to use Data Binding in Xamarin.Forms?
Not only with data source, we can also use Data Binding concept in various scenarios like below:
*View-to-View Bindings: This is the scenario, when we want to link properties of two views on the same page. In this case, you need to set the BindingContext of the target object using the x:Reference markup extension. 
*Backwards Bindings: A single view can have data bindings on several of its properties.
*Binding with Model: Here the scenario is like, a view property is binding with specific class object.
*Binding with Collections: It is scenario, where we want to bind list of objects to view. For example ListView defines an ItemsSource property of type IEnumerable, and it displays the items in that collection.

43. How to make View-to-View Data Binding in Xamarin.Forms with Xaml?
Sometimes we may need to link one property of view with another property of view. For example below Xaml program can describes the scenario is like when we want to control Opacity value of Lable with Silder control Value. 
  1. <?xml version="1.0" encoding="UTF-8"?>  
  2. <ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" x:Class="CustomEntry.ViewtoViewBinding">  
  3.     <StackLayout VerticalOptions="Start" Padding="20,70,20,0" >   
  4.         <Label Text="Lable Opacity Demo" FontSize="Large" VerticalOptions="CenterAndExpand" HorizontalOptions="Center"  Opacity="{Binding Source {x:Reference Name=slider}, Path=Value}" />  
  5.         <Slider x:Name="slider" VerticalOptions="CenterAndExpand" />   
  6.     </StackLayout>  
  7. </ContentPage> 

44. Why we need to use Model-View-ViewModel(MVVM) pattern in Xamarin?
The Model-View-ViewModel pattern can be used on all XAML platforms. Its intent is to provide a clean separation of concerns between the user interface controls and their logic.


Benefits:
  • During the development process, developers and designers can work more independently and concurrently on their components. The designers can concentrate on the view, and if they are using Expression Blend, they can easily generate sample data to work with, while the developers can work on the view model and model components.
  • The developers can create unit tests for the view model and the model without using the view. The unit tests for the view model can exercise exactly the same functionality as used by the view.
  • It is easy to redesign the UI of the application without touching the code because the view is implemented entirely in XAML. A new version of the view should work with the existing view model.
  • If there is an existing implementation of the model that encapsulates existing business logic, it may be difficult or risky to change. In this scenario, the view model acts as an adapter for the model classes and enables you to avoid making any major changes to the model code.

45. What is use of ICommand in Xamarin.Forms?
Typically, when you write an application without using the MVVM pattern, to manage the user’s interaction with the user interface (for example, he clicks on a button) you subscribe to a event handler: this way, a new method will be generated in code (C#) behind, which will contain the code that will be execute when the event is raised.

This approach is that it creates a strong connection between the View and the code: event handlers can be managed only in code behind, but you can’t simply move it to a ViewModel. The solution is to use commands, which are special objects (that implement the ICommand interface) that define the operation to perform when the command is executed.

46.What is NuGet and how it can help in Xamarin App Development?
NuGet is the most popular package manager for .NET development. It is built in to Xamarin Studio 5 and Visual Studio. You can easily search for and add packages/third party libraries to your Xamarin.Forms using either IDE.

47. What does behaviors in Xamarin.Forms?
Behaviors are very important and useful to add functionality to user interface controls without having to subclass them. Instead, the functionality is implemented in a behavior class and attached to the control as if it was part of the control itself. For example adding an email validator to an Entry, controlling an animation, adding an effect to a control.
Xamarin.Forms supports two different styles of behaviors:
  • Xamarin.Forms behaviors: classes that derive from the Behavior or Behavior<T> class, where T is the type of the control to which the behavior should apply.
  • Attached behaviors: static classes with one or more attached properties

48. What are uses of DataPages in Xamarin.Forms?
Data pages allow developers to quickly and easily consume a supported data source and render it using built-in UI scaffolding that can be customized with themes.
Note: Xamarin.Forms DataPages were announced at Evolve 2016

49.How to increase rows & columns space of Grid in Xamarin.Forms?
Yes, we can set space between rows in the Grid using RowSpacing. And also we can sets the distance between columns in the Grid using ColumnSpacing .
  1. <Grid Name="GridSpaceDemo" RowSpacing="3" ColumnSpacing="2"  >  
  2.           <Grid.RowDefinitions>  
  3.             <RowDefinition Height="Auto"/>  
  4.             <RowDefinition Height="Auto"/>  
  5.           <RowDefinition Height="Auto"/>  
  6.           </Grid.RowDefinitions>  
  7.       <Grid.ColumnDefinitions>  
  8.         <ColumnDefinition Width="Auto"/>  
  9.         <ColumnDefinition Width="Auto"/>  
  10.         <ColumnDefinition Width="Auto"/>  
  11.       </Grid.ColumnDefinitions>  
  12.           <!--Grid child items-->  
  13.     
  14.   </Grid>  

50.What is the difference between Modal pages and Modeless pages?
Modal Page: We’ll use modal pages when your application needs some information from the user and you don’t want the user to return to the previous page until that information is provided. Below C# code is used to navigate to specific page name is DetailPage. 
  1. async void ModelPageNavigation ()  
  2. {  
  3.    
  4.     await Navigation.PushModalAsync (new DetailPage ()); //Navigate to Details Page  
  5. }  
Modeless Page: The difference between modal and modeless pages mostly involves the user interface that the operating system provides Back button on the page to return back to the previous page.


  • async void ModelessPageNavigation ()  
  • {  
  •    
  •     await Navigation.PushAsync (new DetailPage ()); //Navigate to Details Page, will create Back button navigation page  
  • }  


  • In next article, I will explain more Xamarin advanced interview questions. And also suggested to read all previous UWP, Windows Phone (Both silverlight and WinRT) interview questions from below links

    1. Top Windows 10 UWP App Development Interview questions (C#-Xaml) – Part1
    2. Top Windows Phone interview questions c# - Part1
    3. Top Windows Phone interview questions c# - Part2 
    4. Windows App Development Tips:Top Basics for Beginners(C#-XAML)
    All the very best for your interview :)

    FeedBack Note:
    Please share your thoughts,what you think about this post,Is this post really helpful for you?I always welcome if you drop comments on this post and it would be impressive.

    Follow me always at @Subramanyam_B
    Have a nice day by  :)