Tweak HTML output of report viewer

Is there anyway to tweak the HTML generation of the Report Viewer output on the fly? We created a couple reports and they work great, but now management would like to embed them directly into emails. And of course, Outlook(w/ Word’s rendering) doesn’t handle the Position:Absolute CSS stuff.

Just wondering if I can get around that in a quick and dirty fashion or if I should just rewrite the reports into something else?

oh drat, no ‘move’ option for forum posts when you make them in the wrong place… :frowning:

Have you thought about using … demail.htm


Oh indeed. I am in fact using it to send the .html that the report viewer generates already.
Sadly, when opened in outlook 2007, it doesn’t show about half of it due to the aforementioned lack of total css support in Outlook2007.

I was just wondering if there was a way to tweak the output from report viewer, via a setting or such, to change how it built the html in the first place.

I did redo one by creating a workable html templete and just inserted the values into it. Just being lazy and didn’t want to have to do it multiple times :smiley:


I might suggest using python to save the html report to a temp location. Then you could read it in and manipulate and send it through email.

You’ll want to use the reports saveAsHTML() function, and then system.file.readFileAsString() to read the file back in.

From there you can use python string methods (providing you know what you’re searching for) to replace the position:absolute stuff with code that is more friendly with your target software.

Hope this helps, talk to you later.

Thanks, I went with a different solution for now(wrote a template and pushed the data into it).

Is there an easy way to show the control characters in a Text Box?(Or rather, Is a CR a \n for this component? If so, i’ll just do a python replace with
for now)

The actual escape characters will probably depend on the OS, but in Windows it looks like it’s ‘\n’. So yeah, you can just use string.replace("\n", “
”) and it should work out fine.