tags:

views:

85

answers:

2

I'm building an XBAP application to sit within an iFrame, which plays media files. I have a button that I want to be able to click once and compose an email with the media files attached. All the code I have written for handling the MAPI has been testing in standard C# application and works, but in most cases won't in the XBAP.

For i have tried to the following:

  1. Written a C# class for handling the MAPI dll
  2. Written a C++ DLL for calling MAPI, and embedded it into the XBAP (extracted when used)so that it can be used when opened.

as i said, none of these method work.

Any suggestions would be greatly appreciated.

A: 

XBAPS have a limited set of permissions and I don't think that includes sending email.

You'd need to create a webservice that sends emails and connect to that.

SillyMonkey
A: 

Are you aware that XBAP application run in a partial trust environment.

You say "in most cases won't in the XBAP" but don't give any indication of exactly what the problems you are experiences are - are you getting compilation errors, security errors, or some other runtime error.

See the following link for details on Partial Security and WPF:

http://msdn.microsoft.com/en-us/library/aa970910.aspx

samjudson