Skip to content

Instantly share code, notes, and snippets.

@gurvinderbini
Created January 15, 2017 08:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gurvinderbini/592e7f4f1822fe0f5c99d548ced253a2 to your computer and use it in GitHub Desktop.
Save gurvinderbini/592e7f4f1822fe0f5c99d548ced253a2 to your computer and use it in GitHub Desktop.
using System;
using System.Collections.Generic;
namespace NewFeature
{
public class MainPageViewModel
{
private object _itemSelectedFromList;
public MainPageViewModel()
{
ItemsList = new List<string>
{
"New York",
"Boston",
"Chicago",
};
}
public List<string> ItemsList { get; set; }
public object ItemSelectedFromList
{
get { return _itemSelectedFromList; }
set
{
_itemSelectedFromList = value;
RaisePropertyChanged(() => ItemSelectedFromList); //in case you are using MVVM Light
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment