Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
355
Export images to Excel/PDF
posted

 Hi,

I have a table which I want to export to excel and pdf formats. The problem I'm having is that, for presentation purposes, some of the cells are rendered with an extra image on the right (for example a smiley, or a health icon).

I do this by overriding the Cell.Text value, adding in some HTML code such as

Cell.Text = Cell.Text + "&nbsp<img src="..." />

You get the idea.

The problem is that, when exporting the data, what I get on the cells is the HTML raw code, and it looks awful.

I would like to know if there is a way to "embed" those images in the exported document.

As I guess this is not possible, I would like to know if there is a workaround I can use to export only the values of the grid instead of the modified values with the HTML code, just for exporting, and then going back to the original grid with icons after.

Many thanks!