By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,871 Members | 1,209 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,871 IT Pros & Developers. It's quick & easy.

Connecting to Outlook from C#

P: 8
Hi All,
I've written code that connects to Outlook and retrieves emails from a folder that resides inside my inbox. My profile is on Exchange Server.

Expand|Select|Wrap|Line Numbers
  1. Outlook._Application olApp = new Outlook.ApplicationClass();
  2. Outlook._NameSpace olNS = olApp.GetNamespace("MAPI");
  3. olNS.Logon("****", "****", true, true);
  4.  
  5. Outlook.MAPIFolder newFolder = olNS.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderInbox);
  6.  
This works fine on my local machine. However, I want to be able to get to my inbox from any machine. Would anyone know how to modify the above code or use different method of connecting to my inbox from a machine other than my own?

Thanks,
S
May 31 '07 #1
Share this Question
Share on Google+
1 Reply


TRScheel
Expert 100+
P: 638
Hi All,
I've written code that connects to Outlook and retrieves emails from a folder that resides inside my inbox. My profile is on Exchange Server.

Expand|Select|Wrap|Line Numbers
  1. Outlook._Application olApp = new Outlook.ApplicationClass();
  2. Outlook._NameSpace olNS = olApp.GetNamespace("MAPI");
  3. olNS.Logon("****", "****", true, true);
  4.  
  5. Outlook.MAPIFolder newFolder = olNS.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderInbox);
  6.  
This works fine on my local machine. However, I want to be able to get to my inbox from any machine. Would anyone know how to modify the above code or use different method of connecting to my inbox from a machine other than my own?

Thanks,
S

After my run of luck with exchange, i would believe you would need to use RPC over HTTP.... though thats just from past experience, not from any technical knowledge
May 31 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.