What are Xamarin and Xamarin Forms?

Prerequisites

The steps given below are required to be followed in order to create simple Android Web View Application, using Xamarin.Forms in Visual Studio 2017.

Step 1

Step 2

Step 3

Step 4

In UWP Project, select Target version & Minimum Version, followed by clicking OK.

Xamarin

Step 5

In this step, go to Solution Explorer -> Portable Class Library, followed by clicking XAML, Insert the code given below the XAML page and save it.

Xamarin

  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" xmlns:local="clr-namespace:WebView" x:Class="WebView.MainPage">
  3. <WebView Source="http://www.google.co.in"> </WebView>
  4. </ContentPage>

Step 6

Step 7

Go to Solution Explorer -> click UWP Application ->Right click, followed by adding the Reference.

Xamarin

Click Cross Platform ->Extension->add the extension given below.

Windows Desktop Extensions for UWP 10.0.143953

Xamarin

Step 8

Now, go to Run option, choose Debug, the list of Android or an iOS or an UWP Simulators, which are available. You can choose any one Simulator and run it.

Xamarin

Step 9

Output

After few seconds, the app will start running on your Android Simulator. You will see your app is working successfully.

Xamarin
Your Web Application was created succesfully

Conclusion

Thus, we learned how to create an Android Web View Application, using Xamarin.Forms in Visual Studio 2017.