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

Display image in Telerik RadGridView Column

0 Answers 161 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Sats
Top achievements
Rank 1
Sats asked on 04 Jun 2012, 12:28 PM
Hello All,

I am using telerik RadGridView control.
In that I have created the first column dynamically and inserted it at Index zero (0).

e.g:

Binding

 

 

bindC = new Binding("Link");

 

DataGrid.Columns.Insert(0,

 

new GridViewDataColumn { Header = "", HeaderCellStyle = Resources["GridViewHeaderCellStyle1"] as Style, CellTemplate = GetDataTemplate("LinkButton", "Link"), DataMemberBinding = bindC });

I have custom web part in sharepoint and in that I have used this telerik RadGridView control.
What I want is I have configured web part with Image library, document library or normal sharepoint list.
So what I really need is if I have configured a document library and suppose in that there are Images as well, based on the image displayed in the RadGridView, the first columns should display the thumbnail of the image.
If the library/list configured contains normal data (means no image), then it should display a default icon/image.

Means based on the the configuration I wnat to display Image/icon based on the list type used.

Also, the Image should be clickable. I want to perform further action on click event of the image/icon.

In the above eg. that I created dynamic column, I am seeing the default Image even if the library configured for web part contains images normal  documents.

If I change to GridViewImageColumn, then some items shows images and others not

Please any ideas on this.
Help is aprreciated.

Thanks.

 

No answers yet. Maybe you can help?

Tags
GridView
Asked by
Sats
Top achievements
Rank 1
Share this question
or