bin/place_order in ib-ruby-0.7.0 vs bin/place_order in ib-ruby-0.7.2
- old
+ new
@@ -9,11 +9,11 @@
require 'rubygems'
require 'bundler/setup'
require 'ib-ruby'
-# First, connect to IB TWS.
-ib = IB::Connection.new :client_id => 1112 # Arbitrary id to identify your script
+# First, connect to IB TWS. Arbitrary :client_id is used to identify your script
+ib = IB::Connection.new :client_id => 1112 #, :port => 7496 # TWS
# Subscribe to TWS alerts/errors and order-related messages
ib.subscribe(:Alert, :OpenOrder, :OrderStatus) { |msg| puts msg.to_human }
wfc = IB::Symbols::Stocks[:wfc]