Quantcast
Channel: Microsoft Dynamics NAV
Viewing all articles
Browse latest Browse all 64865

Blog Post: HTML 2 Image

$
0
0

A while ago, I was working on reporting and was very happy with the new HTML options on the RDLC. But, as you might know, these are actually quite limited…

According to Microsoft, these are the supported tags:
<A>, <FONT>, <H{n}>, <DIV>, <SPAN>,<P>, <DIV>, <LI>, <HN>, <B>, <I>, <U>, <S>, <OL>, <UL>, <LI> (http://msdn.microsoft.com/en-us/library/cc645967.aspx)

Which does mean we are missing a lot of possibilities we do have in basic HTML. For this reason, I created a .NET class which accepts an HTML string and converts it to an image. This image could the easily be added to your RDLC columns to be shown on the report.

The Add-In has a property to crop the image (leaving no white borders) and a function “CaptureWebPageBytes”.

The function accepts the string you wish to set into an image. And if necessary, you can say how wide and high your image needs to be.

You can find a test application inside the file to check it out. All source is included.


Viewing all articles
Browse latest Browse all 64865

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>