Introduction
Xamarin is a platform to develop cross-platform and multi-platform apps (for example, Windows phone, Android and an iOS). In Xamarin platform, the code sharing concept is used. In Xamarin Studio, Visual Studio is also available.
Download code here.
Prerequisites
Xamarin is a platform to develop cross-platform and multi-platform apps (for example, Windows phone, Android and an iOS). In Xamarin platform, the code sharing concept is used. In Xamarin Studio, Visual Studio is also available.
Download code here.
Prerequisites
- Xamarin Studio.
- Xcode.
The steps given below are required to be followed in order to validate an Email address in Xamarin iOS, using Xamarin Studio.
Step 1
Go to Xamarin Studio.
Click New Solution—> select Multiplatform—> Choose Single View app. Native(iOS, Android). Afterwards, click Next.
Step 2
In this step, configure your app. Give app name (Ex:sample) and Organization Identifier and Choose Target Platforms. Now, choose Shared code. Afterwards, click Next.
Step 3
In this step, give your Project Name(Ex: Sample) and Solution Name(EX: Sample). Give the path of your project. Afterwards, click Create.
Step 4
Subsequently, go to Solution . In Solution, get all the files and source in your project. Now, select Main.storyboard and double click to open Main.storyboard page.
Step 5
After opening Main.storyboard, you can design the page, as per your desire.
Step 6
Now, go to Toolbox Window. In Toolbox Window, get all the types of the tools and controls you need to go to Toolbox Window.
Now, scroll down and you will see all the tools and controls. You need to drag and drop Text Field. Now, you need to align Text Field, using constraints.
Step 7
Now, go to the Properties Window. Select Text Field and give Name (Ex:txtEmail).
Step 8
You need to drag and drop the label.
Now, you need to align the label, using the constraints.
Step 9
Now, go to Properties Window. Select Label and give the name (Ex:lblMessage).
Step 10
You need to drag and drop the button.
Now, you need to align the button, using constraints.
Step 11
Now, go to Properties Window. Select the button and give the name (Ex:btnValidate).

Step 12
In this step, go to ViewController.cs page. Write the code given below.
ViewController.cs
Step 1
Go to Xamarin Studio.
Click New Solution—> select Multiplatform—> Choose Single View app. Native(iOS, Android). Afterwards, click Next.
Step 2
In this step, configure your app. Give app name (Ex:sample) and Organization Identifier and Choose Target Platforms. Now, choose Shared code. Afterwards, click Next.
Step 3
In this step, give your Project Name(Ex: Sample) and Solution Name(EX: Sample). Give the path of your project. Afterwards, click Create.
Step 4
Subsequently, go to Solution . In Solution, get all the files and source in your project. Now, select Main.storyboard and double click to open Main.storyboard page.
Step 5
After opening Main.storyboard, you can design the page, as per your desire.
Step 6
Now, go to Toolbox Window. In Toolbox Window, get all the types of the tools and controls you need to go to Toolbox Window.
Now, scroll down and you will see all the tools and controls. You need to drag and drop Text Field. Now, you need to align Text Field, using constraints.
Step 7
Now, go to the Properties Window. Select Text Field and give Name (Ex:txtEmail).
Step 8
You need to drag and drop the label.
Now, you need to align the label, using the constraints.
Step 9
Now, go to Properties Window. Select Label and give the name (Ex:lblMessage).
Step 10
You need to drag and drop the button.
Now, you need to align the button, using constraints.
Step 11
Now, go to Properties Window. Select the button and give the name (Ex:btnValidate).

Step 12
In this step, go to ViewController.cs page. Write the code given below.
ViewController.cs


Join the conversation! Your thoughts help the community grow.