I'm using SPMetal to generate a class for my lists to use in a Sandbox-solution (with Sandbox Visual WebParts).
However, when I generate the classes for a list column of type "Person or Group" with display value "Name with Picture", I only get the string for that person's name back (SPMetal only generates a string property for this field).
[Microsoft.SharePoint.Linq.ColumnAttribute(Name = "Person", Storage = "_personNameWithPicture", ReadOnly = true, FieldType = "User", IsLookupValue = true)]
public string PersonNameWithPicture
{
get
{
return this._personNameWithPicture;
}
set
{
if ((value != this._personNameWithPicture))
{
this.OnPropertyChanging("PersonNameWithPicture", this._personNameWithPicture);
this._personNameWithPicture = value;
this.OnPropertyChanged("PersonNameWithPicture");
}
}
}
Is there any way to get both the person's name and the profile picture, like it does in the default list view?
Thanks