Cannot implicitly convert type 'Telerik.WinControls.UI.GridViewCellInfo' to 'System.Drawing.Image'.
2 Answers, 1 is accepted
0
Dimitar
Telerik team
answered on 19 Mar 2014, 02:23 PM
Hello Mohsen,
Thank you for writing.
The SelectedItem property gives you access to currently selected row of the underlying grid. You can cast it to the appropriate type and access the value of the cell that contains the image:
GridViewDataRowInfo row = radMultiColumnComboBox1.SelectedItem as GridViewDataRowInfo;
Image img = (Image)row.Cells["image"].Value;
Please let me know if there is something else I can help you with.
Regards,
Dimitar
Telerik
DevCraft Q1'14 is here! Watch the online conference to see how this release solves your top-5 .NET challenges.Watch on demand now.
Hi, Mohsen.
Have you ever tried the code offered by Dimitar?
GridViewDataRowInfo row = radMultiColumnComboBox1.SelectedItem as GridViewDataRowInfo;
Image img = (Image)row.Cells["image"].Value;
Did it work well? Or you can google it and select some manual image converters which can be customized by users according to our own favors to help you convert images. Remember to check its free trial package first if possible. I hope you success. Good luck.