开云体育

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

Re: twsapi: parameter list for orderstatus?


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.

Join [email protected] to automatically receive all group messages.