Created
October 28, 2010 19:29
-
-
Save pigoz/652148 to your computer and use it in GitHub Desktop.
Siebel Scripting from Ruby using COM Data Control
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'win32ole' | |
theApp = WIN32OLE.new('SiebelDataControl.SiebelDataControl.1') | |
cs = %{host="siebel://10.0.0.1:2321/Sieb78/EAIObjMgr_ita" Lang = "ITA"} | |
theApp.Login(cs, "uid", "password") | |
bo = theApp.GetBusObject("Order Entry Orders") | |
bc = bo.GetBusComp("Order Entry - Line Items") | |
bc.ClearToQuery() | |
bc.SetSearchSpec("Id", "1-LULZ") | |
bc.ExecuteQuery(0) | |
result = bc.FirstRecord() | |
puts bc.GetFieldValue("Order Id") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment