开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

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.

-----Mensaje original-----
De: cyberbri_2000 [mailto:no_reply@...]
Enviado el: jueves, 04 de julio de 2002 21:45
Para: twsapi@...
Asunto: twsapi: parameter list for orderstatus?

I'm getting an error in VB 6 that says the declaration does not match
the event description.

From the object browser I got this info and coded the sub like this...

Sub tws1_orderStatus(id As Long, status As String, filled As Long,
remaining As Long, price As Single)
'orderstatus event
End Sub


This is from the user guide...
void orderStatus(long id, String status, long filled, long remaining,
float price, permId)


I tried to add permId to the declaration and other combinations but
that didn't work.? Anyone have a working orderstatus declaration??
Not sure what I'm doing wrong.

Thanx,
Brian



To unsubscribe from this group, send an email to:
twsapi-unsubscribe@...



Your use of Yahoo! Groups is subject to the .


cyberbri_2000
 

This gets the same error...

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
order
status event.

Michel.
-----Mensaje original-----
De: cyberbri_2000 [mailto:no_reply@y...]
Enviado el: jueves, 04 de julio de 2002 21:45
Para: twsapi@y...
Asunto: twsapi: parameter list for orderstatus?


I'm getting an error in VB 6 that says the declaration does not
match
the event description.

From the object browser I got this info and coded the sub like
this...

Sub tws1_orderStatus(id As Long, status As String, filled As Long,
remaining As Long, price As Single)
'orderstatus event
End Sub

This is from the user guide...
void orderStatus(long id, String status, long filled, long
remaining,
float price, permId)

I tried to add permId to the declaration and other combinations
but
that didn't work. Anyone have a working orderstatus declaration?
Not sure what I'm doing wrong.


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.

-----Mensaje original-----
De: cyberbri_2000 [mailto:no_reply@...]
Enviado el: jueves, 04 de julio de 2002 22:05
Para: twsapi@...
Asunto: Re: twsapi: parameter list for orderstatus?

This gets the same error...

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
> order
> status event.
>
> Michel.

>?? -----Mensaje original-----
>?? De: cyberbri_2000 [mailto:no_reply@y...]
>?? Enviado el: jueves, 04 de julio de 2002 21:45
>?? Para: twsapi@y...
>?? Asunto: twsapi: parameter list for orderstatus?
>
>
>?? I'm getting an error in VB 6 that says the declaration does not
>?? match
>?? the event description.
>
>?? From the object browser I got this info and coded the sub like
>?? this...
>
>?? Sub tws1_orderStatus(id As Long, status As String, filled As Long,
>?? remaining As Long, price As Single)
>?? 'orderstatus event
>?? End Sub
>
>?? This is from the user guide...
>?? void orderStatus(long id, String status, long filled, long
>?? remaining,
>?? float price, permId)
>
>?? I tried to add permId to the declaration and other combinations
> but
>?? that didn't work.? Anyone have a working orderstatus declaration?
>?? Not sure what I'm doing wrong.




To unsubscribe from this group, send an email to:
twsapi-unsubscribe@...



Your use of Yahoo! Groups is subject to the .


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:
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.
-----Mensaje original-----
De: cyberbri_2000 [mailto:no_reply@y...]
Enviado el: jueves, 04 de julio de 2002 22:05
Para: twsapi@y...
Asunto: Re: twsapi: parameter list for orderstatus?


This gets the same error...

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
> order
> status event.
>
> Michel.

> -----Mensaje original-----
> De: cyberbri_2000 [mailto:no_reply@y...]
> Enviado el: jueves, 04 de julio de 2002 21:45
> Para: twsapi@y...
> Asunto: twsapi: parameter list for orderstatus?
>
>
> I'm getting an error in VB 6 that says the declaration does
not
> match
> the event description.
>
> From the object browser I got this info and coded the sub like
> this...
>
> Sub tws1_orderStatus(id As Long, status As String, filled As
Long,
> remaining As Long, price As Single)
> 'orderstatus event
> End Sub
>
> This is from the user guide...
> void orderStatus(long id, String status, long filled, long
> remaining,
> float price, permId)
>
> I tried to add permId to the declaration and other
combinations
> but
> that didn't work. Anyone have a working orderstatus
declaration?
> Not sure what I'm doing wrong.



Yahoo! Groups Sponsor
ADVERTISEMENT



To unsubscribe from this group, send an email to:
twsapi-unsubscribe@y...



Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service.


Michel
 

开云体育

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


cyberbri_2000
 

Works fine now, thanx for the help! I had price as double instead of
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

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


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
}