locked
Retrieve Emails from Exchange 2000 in ASP.NET/C# RRS feed

  • Question

  • User728897763 posted

    Hi all,

    I'm in the process of developing a web application in which I need to retrieve the contents of various mailboxes in Exchange 2000 - just grabbing the messages themselves from the Inbox - using ASP.NET. I built a working test app using POP3, but it's been suggested to me that there is a better way.

    So my question is - what is the best way to achieve this? I'm not 100% sure what our configuration of Exchange will support (apart from POP3 access) right now, as the relevant person to ask is out of the office, so my query does not exclude any options at the moment. I've researched, and found bits of info about using MAPI, WebDAV, IMAP and POP3 (this seems to be the most 'accessible', with examples more widely available), but I'm still unclear as to what is the most current or best solution.

    Thank you - I'd appreciate your advice / opinion! :)

    Wednesday, August 13, 2008 6:39 AM

Answers

  • User-319574463 posted

     My experiance with such application is that you should use a Windows Service to read the email from exchange (the service can have a domain account and thus be more readily authorised to read from Exchange) and output the mail into a database table. The web application can readily read the table in its database and use it appropriatly.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, August 13, 2008 7:36 AM
  • User-319574463 posted

     The Windows Service could be on any member server or PC that is on the same domain as the Exchange Box. Mail administrators get very touchy about anything on their exchange boxes other than Exchange and its immediate support. As long as the windows service is run by a domain account (not a local account) it should be possible for it to be given the required exchange permissions to send and or recieve.

    You should in the first instance use the Dot Net classes to send / recieve email.

    >And what's the best method for remote retrieval from my web app, if a Windows Service is not an option?
    It start to get very complicated and the security risks increase if you try and run the web application at any more than minimum permissions.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, August 13, 2008 1:06 PM

All replies

  • User-319574463 posted

     My experiance with such application is that you should use a Windows Service to read the email from exchange (the service can have a domain account and thus be more readily authorised to read from Exchange) and output the mail into a database table. The web application can readily read the table in its database and use it appropriatly.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, August 13, 2008 7:36 AM
  • User728897763 posted

    Thank you for this! Would a Windows Service have to be on the Exchange box, and would it need to perform such a function periodically, or could emails be retrieved on demand? I've never created a Windows Service.

    However, even if I were using a Windows Service, my question is - what should I use? That is, CDOEX / WebDAV, etc? And what's the best method for remote retrieval from my web app, if a Windows Service is not an option?

    Wednesday, August 13, 2008 9:18 AM
  • User-319574463 posted

     The Windows Service could be on any member server or PC that is on the same domain as the Exchange Box. Mail administrators get very touchy about anything on their exchange boxes other than Exchange and its immediate support. As long as the windows service is run by a domain account (not a local account) it should be possible for it to be given the required exchange permissions to send and or recieve.

    You should in the first instance use the Dot Net classes to send / recieve email.

    >And what's the best method for remote retrieval from my web app, if a Windows Service is not an option?
    It start to get very complicated and the security risks increase if you try and run the web application at any more than minimum permissions.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, August 13, 2008 1:06 PM
  • User728897763 posted

    Thank you for your help with this, but just to close this thread off- time constraints mean I'm now using POP3 after all!

    Tuesday, August 26, 2008 11:25 AM