This is a migrated thread and some comments may be shown as answers.

Image on GridView with RIA service

3 Answers 119 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Jay
Top achievements
Rank 1
Jay asked on 23 Oct 2009, 10:09 PM

I am trying to show image from a SQL table on SL3 GridView using code below:
<

 

telerikGridView:GridViewImageColumn Header="Picture" Width="Auto" DataMemberBinding="{Binding picture}">

 

 

 

</telerikGridView:GridViewImageColumn>

But it crashes with error:

 

Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED))

   at MS.Internal.XcpImports.CheckHResult(UInt32 hr)
   at MS.Internal.XcpImports.BitmapSource_SetSource(BitmapSource bitmapSource, CValue& byteStream)
   at System.Windows.Media.Imaging.BitmapSource.SetSourceInternal(Stream streamSource)
   at System.Windows.Media.Imaging.BitmapImage.SetSourceInternal(Stream streamSource)
   at System.Windows.Media.Imaging.BitmapSource.SetSource(Stream streamSource)
   at Telerik.Windows.Controls.BinaryImageConverter.Convert(Object value, Type targetType, Object parameter, CultureInfo culture)
   at System.Windows.Data.BindingExpression.ConvertToTarget(Object value)
   at System.Windows.Data.BindingExpression.GetValue(DependencyObject d, DependencyProperty dp)
   at System.Windows.DependencyObject.RefreshExpression(DependencyProperty dp)
   at System.Windows.Data.BindingExpression.RefreshExpression()
   at System.Windows.Data.BindingExpression.SendDataToTarget()
   at System.Windows.Data.BindingExpression.SourceAquired()
   at System.Windows.Data.BindingExpression.DataContextChanged(Object o, DataContextChangedEventArgs e)
   at System.Windows.FrameworkElement.OnDataContextChanged(DataContextChangedEventArgs e)
   at System.Windows.FrameworkElement.OnTreeParentUpdated(DependencyObject newParent, Boolean bIsNewParentAlive)
   at System.Windows.DependencyObject.UpdateTreeParent(IManagedPeer oldParent, IManagedPeer newParent, Boolean bIsNewParentAlive, Boolean keepReferenceToParent)
   at MS.Internal.FrameworkCallbacks.ManagedPeerTreeUpdate(IntPtr oldParentElement, IntPtr parentElement, IntPtr childElement, Byte bIsParentAlive, Byte bKeepReferenceToParent)


Any suggestion?

Thanks 

3 Answers, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 26 Oct 2009, 12:33 PM
Hello Jay,

What is the type of the image in the database? Is it by any chance a GIF? We were able to reproduce this same exception with a GIF file. The reason for it is that Silverlight does not support GIF files.

It would be best if you can send us a small sample project that reproduces this behavior or at least send us several images from your database.

We are looking forward to hearing from you.

Best wishes,
Ross
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Jay
Top achievements
Rank 1
answered on 26 Oct 2009, 04:40 PM
Hi,

How do I send my project, DB backup here? It doesn't let me attach zip or db backup here.

Thanks,
Jay
0
Vlad
Telerik team
answered on 27 Oct 2009, 05:58 AM
Hello Jay,

You can open support ticket.

Sincerely yours,
Vlad
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
GridView
Asked by
Jay
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Jay
Top achievements
Rank 1
Vlad
Telerik team
Share this question
or