示例#1
0
 def __init__(self, account_num, account_type):
     self.obj = win32com.client.Dispatch('CpTrade.CpTd5339')
     self.obj.SetInputValue(0, account_num)
     self.obj.SetInputValue(1, account_type)
     self.obj.SetInputValue(4, '0')
     self.obj.SetInputValue(6, '0')
     self.obj.SetInputValue(7, 20)
     self.conn = connection.Connection()
示例#2
0
文件: order.py 项目: wingsof/trader
 def __init__(self, account_num, account_type, listener):
     self.conn = connection.Connection()
     self.listener = listener
     self.realtime_order = win32com.client.Dispatch('DsCbo1.CpConclusion')
     handler = win32com.client.WithEvents(self.realtime_order,
                                          _OrderRealtime)
     handler.set_params(self.realtime_order, listener)
     self.realtime_order.Subscribe()
示例#3
0
 def __init__(self, account_num, account_type):
     self.account_num = account_num
     self.account_type = account_type
     self.obj = win32com.client.Dispatch('CpTrade.CpTd0314')
     self.conn = connection.Connection()