private WPTask FromAPItoDomain(Task t) { var _t = new WPTask(); _t.ID = t.ID; _t.FullName = t.FullName; _t.WBS = t.WBS; _t.Name = t.Name; _t.SortOrder = t.SortOrder; _t.ProjectName = t.Details.ProjectHeader.Name; _t.CustomerName = t.Details.CustomerHeader.Name; _t.StartDate = t.StartDate; return _t; }
private void CreateLiveTile(WPTask selected) { StandardTileData tiledata = new StandardTileData { Title = selected.Name.MaxLength(10), BackTitle = selected.CustomerName.MaxLength(10), BackContent = selected.ProjectName.MaxLength(10), BackgroundImage = new Uri("/Images/ApplicationIcon.png",UriKind.Relative) }; ShellTile tileToFind = ShellTile.ActiveTiles.FirstOrDefault(x => x.NavigationUri.ToString().Contains("AddRegistrationPage.xaml?selectedItem=" + selected.ID)); if (tileToFind == null) { ShellTile.Create(new Uri("/AddRegistrationPage.xaml?selectedItem=" + selected.ID, UriKind.Relative), tiledata); } }