views:

77

answers:

2

I have recently implemented something in a rails application that allows me to read appointments of the Outlook calendar. This works sufficiently well. But when I tried to use it in production mode by starting it through mongrel_service, the whole thing stopped working and gave me the following error message:

failed to create WIN32OLE object from `Outlook.Application'
HRESULT error code:0x80080005
  Starten des Servers fehlgeschlagen (german for: start of server failed)

So the problem seems to be the wrong account for the mongrel_service. Is it possible to configure it correctly?

+1  A: 

Reading up on some forum posts, it seems that running your application in service mode will not be easy - or even feasible (for example have a look at: outlook and win32 service).

That being said, perhaps there are other ways to read calendar items from an Exchange server (assuming you are using Exchange), like for example using IMAP (Exchange calendar to Ruby object).

Hans Doggen
I have done one more test, and it seems that you are right. My next try will be to extract the function in a little script that I may start at will, that is not part of the rails application, but changes the data there. Not the best solution, but should be sufficient.
mliebelt
A: 

As a workaround, I have written the following script:

ruby script\runner 'AppointmentController.new.refresh_no_redirect'

I start this script regularly instead of using the button inside the Rails application. Because I start it by hand, my credentials are used and it works pretty well. So no solution for the original question, but one workaround that works well for me.

mliebelt