Keyboard Shortcuts
ctrl + shift + ? :
Show all keyboard shortcuts
ctrl + g :
Navigate to a group
ctrl + shift + f :
Find
ctrl + / :
Quick actions
esc to dismiss
Likes
Search
twsapi: parameter list for orderstatus?
Michel
开云体育It
works for me (I use VB 5) but I pass parameters 'ByVal' in the order status
event.
?
Michel.
|
cyberbri_2000
This gets the same error...
toggle quoted message
Show quoted text
Sub tws1_orderStatus(ByVal id As Long, ByVal status As String, ByVal filled As Long, ByVal remaining As Long, ByVal price As Double) It would be helpful to see your declaration line, if it's different in any way. Brian It works for me (I use VB 5) but I pass parameters 'ByVal' in the -----Mensaje original----- |
Michel
开云体育'price' must be Single, not Double. Here is my declaration
line:
Private Sub tws_orderStatus(ByVal id As Long, ByVal Status As String,
ByVal Filled As Long, _
ByVal Remaining As Long, ByVal price As Single) Michel.
|
marinindextrader
the word Status is a reserved property name for certain objects
When I type it into my editor it automatically caps the lead letter.... Try changing the variable declaration to a different name, such as TWSstatus or something There are three and counting uses of VB keywords or propertey names in the standard TWS API: "right", "currencey" and Now "status" Pretty lame IMHO Scott PS please let us know if this resolves the issue --- In twsapi@y..., "Michel" <migurull@t...> wrote: 'price' must be Single, not Double. Here is my declaration line:String, ByVal Filled As Long, _ByVal filled As Long, ByVal remaining As Long, ByVal price As Double)different in any way.the > ordernot > matchLong, > remaining As Long, price As Single)combinations > butdeclaration? > Not sure what I'm doing wrong.Service. |
Michel
开云体育Yes,
not very good names for variables, but till now seems to not cause much
problems.
?
Michel.
|
cyberbri_2000
Works fine now, thanx for the help! I had price as double instead of
toggle quoted message
Show quoted text
single, which you pointed out. Private Sub tws1_orderStatus(ByVal id As Long, ByVal Status As String, ByVal Filled As Long, ByVal Remaining As Long, ByVal price As Single) the word Status is a reserved property name for certain objects |
Richard Foulk
This does sound a bit like a bug and should probably be reported to IB.
Richard } Yes, not very good names for variables, but till now seems to not cause much } problems. } } Michel. } -----Mensaje original----- } De: marinindextrader [mailto:marinindextrader@...] } Enviado el: jueves, 04 de julio de 2002 22:25 } Para: twsapi@... } Asunto: Re: twsapi: parameter list for orderstatus? } } } the word Status is a reserved property name for certain objects } } When I type it into my editor it automatically caps the lead } letter.... } } Try changing the variable declaration to a different name, such as } TWSstatus or something } } There are three and counting uses of VB keywords or propertey names } in the standard TWS API: } } "right", "currencey" and Now "status" } } Pretty lame IMHO } } Scott } } PS please let us know if this resolves the issue } |
to navigate to use esc to dismiss