title: RDO Outlook Redemption access mailbox from test server
body: <p>I've built a web app that use Redemption to read a mailbox, let's call it "custom@domain.com".  It works fine using localhost but when I deploy it I get this exception.</p>
  
  <blockquote>
    <blockquote>
      <p>Error System.Runtime.InteropServices.COMException (0x80004005):
      Creating an instance of the COM component with CLSID
      {29AB7A12-B531-450E-8F7A-EA94C2F3C05F} from the IClassFactory failed
      due to the following error: 80004005. at
      System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean
      publicOnly, Boolean noCheck, Boolean&amp; canBeCached,
      RuntimeMethodHandleInternal&amp; ctor, Boolean&amp; bNeedSecurityCheck) at
      System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean
      skipCheckThis, Boolean fillCache) at
      System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly,
      Boolean skipVisibilityChecks, Boolean skipCheckThis, Boolean
      fillCache) at System.Activator.CreateInstance(Type type, Boolean
      nonPublic)</p>
    </blockquote>
  </blockquote>
  
  <p><strong>I'm guessing my server is using its network user as the default user to logon to the mailbox, instead of the current windows NT user accessing the web app. How do I get the server or my RDO code to use the current NT user using the app with RDO?</strong> </p>
  
  <p>I have installed MAPI Extension on my server and registered the dll in the registry.</p>
  
  <p>My RDO code looks like this  </p>
  
  <pre><code> RDOSession Session = null;
          rdoDefaultFolders olFolderInbox = rdoDefaultFolders.olFolderInbox;
  
          Session = new RDOSession();//this throws the exception above
          Session.LogonExchangeMailbox("username@domain.com", outLookServer);  
           objFolder = Session.GetDefaultFolder(olFolderInbox);
  </code></pre>