Any time the property get throws an error during binding, it wraps it in the binding exception that you're getting.
You'll need to store off the data into a byte[] and check it's length to make sure there's actually data. While you're at it, you might as well catch any exceptions and return a placeholder if you encounter one.
public System.Drawing.Bitmap PrimaryImage
{
get
{
if (this.Count > 0 && this.CurrentRow != null)
{
try
{
using (IwbProductImages iwbProductImages = new IwbProductImages())
{
byte[] imageData = iwbProductImages.GetPrimaryImage(this.Guid);
if ((imageData?.Length ?? 0) > 0)
{
using(MemoryStream ms = new MemoryStream(imageData))
{
return new System.Drawing.Bitmap(ms);
}
}
else
{
//-- There is no image, so return either nothing or a placeholder
return null;
//return My.Resources.NoImagePlaceholder;
}
}
catch
{
//-- There was some error loading the image, so return either nothing or a placeholder
return My.Resources.ErrorImagePlaceholder;
//return null;
}
}
//-- No current row in the BO