Symmetri Developer Blog

May 11, 2009

View MHTML in Flex?

General, Flash/Flex, .NET/C# - By Shourov Bhattacharya

Everything you need for a webpage in one file, including external links to images, Flash files etc? Sounds like a good idea I guess; it would mean that you could easily email a single webpage to someone for offline viewing, for example. This was, I presume, the idea behind the MHTML format, which MIME-encodes a HTML webpage and associated resources into one long binary file. However, the problem is that very few browsers support the display of MHTML files natively. Internet Explorer does, but not Firefox, Safari or Google Chrome.

In my particular case, I have a bunch of reports generated by a third-party which are saved as MHTML files which need to be displayed within a Flex iFrame component (which is basically a floating browser container). I could display directly in the browser frame, in which case only users on IE will see the display. I could get the client to use a MHTML to HTML converter software. Or I could write my own server-side code to do the conversion on-the-fly, maybe using this code as a starting point.

1 Comment »

  1. Hi everyone. Arguments are to be avoided; they are always vulgar and often convincing.
    I am from Africa and now teach English, please tell me right I wrote the following sentence: ” Glaeser, suggests into other territories for monitoring closet: confirmed today shares for problems, facilities, and connotations.”

    With love :-(, Duscha.

    Comment by Duscha — October 20, 2009 @ 10:24 am

Leave a comment

Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>



Anti-spam measure: please retype the above text into the box provided.

Get free blog up and running in minutes with Blogsome
Theme designed by Janis Joseph