Hi. I know this is more than 2 years old, but for some of us, this may
prove useful. When I query 'COM' in this group, I mainly get results
of how to use COM to access Ruby classes, although most of us I think
want to do the opposite (use Ruby, say to access Lotus Notes).
I finally found a post that said "WIN32OLE.new" is the rough equivalent
of CreateObject. While the pickaxe book does use WIN32OLE.new, perhaps
the 3rd edition could point that out for us new to Ruby struggling with
CreateObject.
So, here is the answer to it:
require 'win32ole'
session = WIN32OLE.new("Notes.NotesSession")
puts session.UserName
notesdb = session.GetDatabase("servername", "database.nsf")
puts notesdb.Title
I sure hope this helps someone out there as I'm new to Ruby as well.