public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { OrganizationShowOnMap organization = value as OrganizationShowOnMap; //if (organization != null && organization.Latitude != null && organization.Longitude != null) //{ // return new Location(organization.Latitude.Value, organization.Longitude.Value); //} return(null); }
public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { OrganizationShowOnMap organization = value as OrganizationShowOnMap; if (organization != null && organization.Latitude != null && organization.Longitude != null) { if (organization.IsOwned) { return(new BitmapImage(new Uri("pack://application:,,,/HabilimentERP;Component/Images/smallheart.png"))); } else { return(new BitmapImage(new Uri("pack://application:,,,/HabilimentERP;Component/Images/smallheartblue.png"))); } } return(null); }