Reputation: 3467
I'm trying to display small image inside devexpress grid. My controller return an image file to my view which is fine(please do not advise me to store image path in my db instead file itself, this is not the question here) to continue I'm getting image in my view calling
Url.Action("GetImage", "Property", new {id = image.Id })
Thats working fine except in devexpress gridview.
If anyone have expirience with DevExpressHelper.WriteToResponse()
and know how to use it to properly render <img width="50" height="50" src="/Property/GetImage/5" alt="">
inside devexpress gridview please share.
Thanks
Upvotes: 0
Views: 5806
Reputation: 9300
The DevExpressHelper.WriteToResponse method seems to be obsolete.
I believe you can use the approach suggested in the http://www.devexpress.com/issue=Q313518 DX KB as a starting point.
Upvotes: 1
Reputation: 10347
The grid supports templates. One template type is for styles.
Have a look at this demo: http://demos.devexpress.com/MVC/GridView/Templates
For ASP.NET WebForms you could look here http://demos.devexpress.com/ASPxGridViewDemos/Templates/Template.aspx
Edit: Provided WebForms demo, when a MVC demo would have appropriate
Upvotes: 0