Skip to content

Instantly share code, notes, and snippets.

@damirarh
Created May 5, 2013 08:35
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 damirarh/5520143 to your computer and use it in GitHub Desktop.
Save damirarh/5520143 to your computer and use it in GitHub Desktop.
public ViewModel()
{
Init();
}
private async void Init()
{
var file = await Package.Current.InstalledLocation.GetFileAsync(@"Assets\Text.txt");
Text = await FileIO.ReadTextAsync(file);
}
public string Text
{
get { return _text; }
set
{
if (value == _text) return;
_text = value;
OnPropertyChanged();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment