views:

1163

answers:

4

I'm using a C# MailMessage to attach a wave file (8K) to an email message. I'd like to provide a player within the body of that email message that will play that wave file if the user chooses to do so. I've tried using the embedded <object> version of WMP, and a cid: reference to the file, but Outlook 2003 rejects the object tag and won't run it. If it helps, I know my users will be on Outlook 2003.

+1  A: 

If it don't support objects tags, then try the Embed tag instead:

http://www.mioplanet.com/rsc/embed_mediaplayer.htm

I don't know it if works, but it is worth a shot :)

Jesper Blad Jensen aka. Deldy
A: 

I would try using the EMBED tag. I'm not too surprised that OBJECT doesn't work, as invoking an ActiveX control is a potential "security hole" of sorts in the email system. I'm not sure that EMBED would work either though, and that's probably by design. Many users would find that behavior undesirable (their email being able to take multimedia actions on opening in Outlook) and the expected user experience is to have attachments listed with the option to execute them on click. The alternative might be to have a link they could click that would open a web page with the multimedia embedded, if you don't want them to have to play it locally on their associated multimedia app.

Grank
A: 

I don't think this is possible as ActiveX and Javascript are disabled in Outlook.

It seems like it would be better to just link to a web page that has an embedded player with the audio file.

Timothy Lee Russell
A: 

If you know the message recipients are running Outlook (which implies you're using this internally), you might be able to accomplish something even better by incorporating your player controls into a custom Outlook form.

Mike Powell