For some reason when I put
"Img/Covers/Medium/106.jpg"
EDIT:
<Image Grid.Column="0" Stretch="None" HorizontalAlignment="Left" Source="Img/Covers/Medium/106.jpg" Margin="7,0,0,0"></Image>
As the Source for an Image, it works perfectly. But when I try to bind the Source to a property defined as such, it doesn't find it.
public virtual Uri MediumImgURI {
get { return new Uri("Img/Covers/Medium/106.jpg"); }
}
EDIT:
<Image Grid.Column="0" Stretch="None" HorizontalAlignment="Left" Source="{Binding Path=MediumImgURI}" Margin="7,0,0,0"></Image>
Is there something special I have to do to get the latter case to work?
EDIT: Also, making that property a string, instead of Uri causes it to work, but this is an over-simplification - I really need to get it to work with the property as Uri.
EDIT:
When I was linking to images that were in my website, and not my SL app, I had this code (which worked)
public virtual string MediumImgURI {
get { return new Uri(App.Current.Host.Source, String.Format("../Img/Medium/{0}.jpg", CurrentBook.smallID)); }
}
When linking instead to an image in my SL app I thought I could just leave off the first parameter, but it appears not.