From: David Mullet Date: 2008-03-28T01:41:12+09:00 Subject: Re: MAPI Logon Jeff Miller wrote: > this is actually simpler to read, sorry- > > so now I've got a simple 2-liner like so: > > require 'win32ole' > mapiSession = WIN32OLE.new('Mapi.session') > > with this error: > test_mapisession.rb:3:in `initialize': unknown OLE server: > `Mapi.session' (WIN32OLERuntimeError) > HRESULT error code:0x800401f3 > Invalid class string from test_mapisession.rb:3:in `new' > from test_mapisession.rb:3 > > Any suggestions? > > Thanks, > - Jeff I think you may need to have CDO (or CDONTS) installed separately in order to call access the MAPI namespace directly. I think MAPI.Session resides in the CDO.dll file. Otherwise, you can call it through Outlook (assuming you have Outlook installed): require 'win32ole' outlook = WIN32OLE.new('Outlook.Application') mapi = outlook.GetNameSpace('MAPI') http://rubyonwindows.blogspot.com/search/label/outlook Hope that helps. David http://rubyonwindows.blogspot.com -- Posted via http://www.ruby-forum.com/.