Preview EML files

Z

Zdravko

Hi all
does somebody know how to preview EML files in Webbrowser control
(Shell.Explorer.2) ?

Thank you
Zdravko
 
Z

Zdravko

Hi
I am looking for general option, for XP and above, from IE 6 and above, with
and without Windows LIVE.
I will preview saved message inside my app.
Have EML files, and will preview those files in webbrowser control (or any
other which can display it).
I can rename it to MHT, it works fine, but
sometime encoding is not right (it can be different encoding for each EML).

Thank you
 
Z

Zdravko

Hi
is there other option?
I mean, I need to see email body inside my app.

Zdravko
 
R

rob^_^

Hi Zd,

There is the outlook listview control to view your outlook folders and
launch the outlook.

Inject this js snippet into a web page hosted in your WebBrowser control

document.write('<OBJECT style=\"left:200px\"
classid=\"CLSID:0006F063-0000-0000-C000-000000000046\" id=\"ViewCtlFolder\"
codebase=\"http://activex.microsoft.com/activex/controls/office/outlctlx.CAB#ver=9,0,0,3203\"
tabIndex=\"1\" VIEWASTEXT>');
document.write('<param name=\"Namespace\" value=\"MAPI\">');
document.write('<param name=\"Folder\" value=\"Inbox\">');
document.write('<param name=\"Restriction\" value=\"\">');
document.write('<param name=\"DeferUpdate\" value=\"0\">');
document.write('</OBJECT>');

or you can host the control in a Windows Form. Use CreateObject.

For further tips see the .eml file extension handler entries in your
registry.

If you are writing your own POP server, then that is a different bag of
fish.

Regards.
 
P

PA Bear [MS MVP]

EML files are associated with Outlook Express, Windows Mail, and Windows
Live Mail, not Outlook (whose messages are MSG format).
 
Z

Zdravko

Hi
many thanks for you mail.

I am using Outlook ViewCtl for messages display (on left side of my app).
Then (on Selection event) I am saving message to disc.
In that moment I run code which displays saved message in Webbrowser control
(on right or bottom side of my app).
Now, you tell me that I put this code into Webbrowser control.
At first moment, I think that that code will display Inbox Folder?
I will try that but I hope that you understand that I need message
(HTMLBody) of EML?

Zdravko
 
Z

Zdravko

Hi
Ok, but I am using Redemption (http://www.dimastr.com/redemption/) to save
Outlook message
to MHT, or EML or HTML ... and to avoid security message.

MHT works OK, but it also includes message header's which I do not need
(From: To: Subject ...)
HTML works OK on Outlook 2007 because it saves images to separate
folder(Outlook 2003 do not do that)
EML is just what I need - without header, but with embeded images, BUT ...
it will not handle encoding on proper way, like MHT do.
Now, I need to find a way that message preview goes fast (if I go to remove
header or go to inject some code in each
message, it slow's down preview)

Zdravko
 
P

PA Bear [MS MVP]

Repeat after me:

1. An EML file is *not* an Outlook message and will not open in Outlook.

2. An EML file *is* an Outlook /Express/ (or Windows Mail or Windows Live
Mail) message and will open in any of those applications.

3. An Outlook message has an MSG extension.

4. Outlook and Outlook Express are /not/ the same application.
 
Z

Zdravko

Hi
looks you are working in Microsoft?

Repeat after me:

1. An EML file is *not* an Outlook message and will not open in Outlook.

I will not open EML file in Outlook. I have that file saved on my HD, and
wil preview that message.

2. An EML file *is* an Outlook /Express/ (or Windows Mail or Windows Live
Mail) message and will open in any of those applications.

I will not open EML file in Outlook. I have that file saved on my HD, and
wil preview that message.
 
P

PA Bear [MS MVP]

MS MVPs neither work for nor represent Microsoft.

No one from Microsoft monitors this newsgroup: We're all voluteers.

An EML file will not and cannot open in OL or, I suspect, any application
other than OE, WinMail, or WLMail (at least not in a usable format).
 
Z

Zdravko

Ok
as you allready understand, I do not need to open EML in Outlook or Outlook
express.
I just need to preview EML message in Webbrowser or some other control -
not in Outlook, not in Outlook Express.
I will preview it inside my app.

Everything works fine if I rename EML to MHT and preview it in Webbrowser,
with:
WebbrowserCtrl.Navigate2("MyMhtFile.mht","")
You can try yourself (rename EML to MHT and open it in Internet Explorer),
or
in Internet Explorer ActiveX control - Shell.Explorer.2

BUT
encoding is not properly displayed if EML contain only text.

Zdravko
 
P

PA Bear [MS MVP]

WYSIWYG
Ok
as you allready understand, I do not need to open EML in Outlook or
Outlook
express.
I just need to preview EML message in Webbrowser or some other control -
not in Outlook, not in Outlook Express.
I will preview it inside my app.

Everything works fine if I rename EML to MHT and preview it in Webbrowser,
with:
WebbrowserCtrl.Navigate2("MyMhtFile.mht","")
You can try yourself (rename EML to MHT and open it in Internet Explorer),
or
in Internet Explorer ActiveX control - Shell.Explorer.2

BUT
encoding is not properly displayed if EML contain only text.

Zdravko
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top