Picker in Xamarin Forms

Posted by seven.srikanth@gmail.com at 30-11-2017 18:04:23 in Tutorials



You can add the below code to your xamarin forms project to add a picker to your UI.
Steps:
1. Add this code to Xaml file.
 
<Picker x:Name="numberpicker" Title="Number of Cans" />
2. Add the below code to Init Method.
 
var numberslist = new List();
 
for (int i = 0; i < 100; i++)
{
       numberslist.Add(i);
}

numberpicker.ItemsSource = numberslist;
3. Run the Program.
Screenshot of Picker:
Thanks.

Tags: Picker; Xamarin Forms;



0 Comments
Login to comment.

Recent Comments

Be the first to Comment. You can ask a Query or Share your toughts or Just say thanks.