Class Quickbooks::OleAdapter::Ole
In: lib/quickbooks/adapters/ole_adapter.rb
Parent: Object



ole  [R]  Simply holds the actual OLE object.

Public Class methods

Pass in the OLE name of the application you want connected to, and the name of a type library, if you need one.

Public Instance methods

Finds an OLE variable in the OLE type library, if you specified one in new(). This navigates the OLE classes and constants for you and returns the variable that matches the var_name you specify. This is used with Quickbooks to get the qbFileOpenDoNotCare parameter to pass to the OpenConnection2 method:

  @quickbooks ='QBXMLRP2.RequestProcessor', 'QBXMLRP2 1.0 Type Library')
  @quickbooks.OpenConnection2('','Sample Application',@quickbooks.get_variable('localQBD'))
  @session = @quickbooks.BeginSession('',@quickbooks.get_variable('qbFileOpenDoNotCare'))

method_missing sends all other methods to the OLE object, so you can treat this object as your OLE object.