开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育
Date   
Please, help
DAVID it's working U R LifeSAVER.. thank you so much Andrew Service.
Started by multicen2002 @
twsapi: Please, help 8
First, your ORDERID - 1 could be a PROBLEM - generate a larger number and increase by delta of 10 or more ( still first order may cause duplicate error - keep trying or increase first and then place an order) after Expire Date - the strike price use 0 right? use "" instead on the exchange not sure - use "GLOBEX" if after the other changes will not make it work(dont trade ES) again for currency use "" This should work David
Started by David @ · Most recent @
Please, help
Please, will you overrite my code line to work ?? it is not working - market , limit..NONE thanx David Andrew Service.
Started by multicen2002 @
Please, help
Hi, I am working on my VB API for IB platform. Thanx to ppl like you, everything starting to work just fine. BUT.. I wasted 1 week trying to send limit order from my box. what is wrong with this code ?? ---------------------------------------- code ---------------------------------------- Private Sub Command4_Click() Tws1.placeOrder 1, "BUY", 1, "ES", "FUT", "200209",_ LastPrice, , "SMART", , "LMT", LastPrice, 0 End Sub Please, help .. multicen2002@...
Started by multicen2002 @
Demo Server Question
To any and all... I have never used the demo server. I have always used my accounts...for testing What is up with the demo server? When I fire up my client side TWS what special user name and password are required to access the demo server? I have a suspicion that you need to log on through the web based Java platform to access the demo server accounts...I hope I am wrong... Thanks Scott
Started by marinindextrader @
Why does IB API renumber order id's after internet disconnect?
This message was originally posted on IB's API forum. I Thought it worthy of our archives and discussion. Posted on Wednesday, June 19, 2002 - 06:26 am: ---------------------------------------------------------------------- ---------- Dear IB, There is a problem with the ActiveX API/TWS interface after a disruption of the internet connection to IB. To demonstrate this problem using the Excel sheet do this: 1 - Place a stop or limit oder (order status will change to 'Submitted' or 'Presubmitted' depending on ordertype and exchange). Write down the assigned order id. In this example I assume it is 123. 2 - Fake a disruption of your internet connection by unplugging the network cable from your PC till TWS show the grid. 3 - Plug in the cable again, the grid disappears and TWS shows quote updates again. So far so good. 4 - Now try to cancel the order - You get an error "Can't find order with id 123" 5 - If you request open orders you see the order Id has changed (in our case from 123 to 124). Questions: What is the correct procedure to cancel the order? Why does IB renumber order id's after a disruption of the internet connection? Note: - This behaviour doesn't match the API documentation for cancelOrder () which tells you to use the ID that was specified previously in the call to placeOrder(). - This also explains the 'Duplicate order id' messages people have been seeing lately. - In the example above we used cancelOrder() but placeOrder() (when changing orders) has the same problem. - We used the most current Release of TWS and the API Regards, Pieter
Started by marinindextrader @
OCA updateExtended(), extended properties, etc, etc
...thanks for keep us up to date......seriously ...post any and all peculiarities you find with the OCA process... Scott
Started by marinindextrader @
updateExtended(), extended properties, etc, etc 4
Thanks Elliot, However, I have read the TWS docs and understand the purpose of OCA. That was never the question. The placeOrder() method doesn't include in its declaration a variable for sending an OCA identifier, nor does it allow for TIF or Transmit to be sent with the individual orders. Could someone explain how to implement these properties on an order to order basis? Thanks
Started by mickjenks @ · Most recent @
twsapi: Timing of events
Michael, If you use a common function for both price and size, you will see that the price comes first but as one person stated correctly they would have to be independent events. So when a new price? and a new size is traded the price comes first, otherwise they work separately. All other comments are valid -? no hope for volume. In my program I drive the whole program of displaying data in modified bar format on 5 different forms representing different time frames, calculating hundreds of different indicators that are created as objects,?and respond to my key events for orders - it works very well and very quickly. However, I use only one instrument that I trade and don't use volume too seriously as I don't think it is so relevant in futures. Hope it was of some help David
Started by David @
twsapi: Re: Timing of events 2
Thanks Scott, this is as I understand it. So there is no way to detect various trades at the same price and size? This could be a very bad issue because it is important (at least for me, and I think for many people) to compute volume along the day. ? Michel.
Started by Michel @ · Most recent @
twsapi: Timing of events
When I started working with TWS ActiveX with VB I explored tickPrice and tickSize first. My observation was that either event occurred once a second and only if a number changed. You could build a set of one second bars of price, or any multiple of it (say 60 seconds), that would be reasonably accurate for trades, bids, and asks. You could develop a concept of the depth of the market by averaging out all the ask sizes for a minute. Ditto for bid sizes. No way can you get anything resembling the tick stream from this data. I don't think IB wants to get into the datafeed business. RCarey
Started by Robert Carey @
C# .NET + TWS ActiveX = 'Catastrophic failure' exception?
I have connected fine using Java and C++ API to TWS, however using Visual Studio.NET and C#, I get 'An unhandled exception of type: System.Runtime.InteropServices.COMException occured in mscorlib.dll: Catastrophic failure' I am doing the following - Start TWS running locally. - TWS: Settings->Enable ActiveX and Socket Clients - Create new C# project - Solution Explorer: Add Reference: Tws ActiveX Control module (Tws.ocx) - Add Button with handler and code: using TWSLib; . . TwsClass myTws = new TwsClass(); myTws.connect("", 7496); . . - and run the program. If I call any function or retrieve a property from the ActiveX control I get the same exception. Any thoughts? Anyone succesfully got C# + TWS API working? thanks, PJ
Started by pjslim99 @
twsapi: Java API 10
I am not familiar with Java, but you need some sort of system call Sleep(int timeout_msecs), so that the process blocks until the timeout occurs. This functionality is provided by the OS. --- usernew <no_reply@...> wrote: __________________________________________________ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com
Started by Todd Turner @ · Most recent @
AW: twsapi: Java API
You should look at EClientSocket.java: ? It spawns an asynchronous thread with tm_reader = new EReader( this, dis); ? The wrapper functions are called from this thread whenever a message is received by the client.? So there is no need to wait!? It’s done all asynchronously. ? Gernot ? -----Ursprüngliche Nachricht----- Von: usernew [mailto:no_reply@...] Gesendet: Tuesday, June 18, 2002 4:24 PM An: twsapi@... Betreff: twsapi: Java API ? My program currently is structured as follows: class TWS implements EWrapper { ? public void requestdata(...) ? public void tickPrice(...) ? public void tickSize(...) ? ... ? public void wait_trans() { ??? for(i=0; i < xxxxx; i++); ? } } public class Main { ?? tws.connect(); ?? for(i=0; i ????? tws.requestdata(...) ?? tws.wait_trans(); ?? tws.disconnect(); } Is there a better way to structure this program ? My concern is wait_trans(). It is continuously eating up cycles. My program does not need to do anything while it is waiting for the arrays to be populated, but I would still like to wait without consuming cycles. Thanks in advance To unsubscribe from this group, send an email to: twsapi-unsubscribe@... Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
Started by gernot.ullrich@... @
Java API
My program currently is structured as follows: class TWS implements EWrapper { public void requestdata(...) public void tickPrice(...) public void tickSize(...) ... public void wait_trans() { for(i=0; i < xxxxx; i++); } } public class Main { tws.connect(); for(i=0; i<n; i++) tws.requestdata(...) tws.wait_trans(); tws.disconnect(); } Is there a better way to structure this program ? My concern is wait_trans(). It is continuously eating up cycles. My program does not need to do anything while it is waiting for the arrays to be populated, but I would still like to wait without consuming cycles. Thanks in advance
Started by usernew @
twsapi: Re: VB and ActiveX....updateExtended() Method????
As with many features, OCA functionality is parallel in the API and the GUI, so reading the TWS docs on this would be a good idea. The OCA string is an identifier assigned by you to group orders together. If an order with an OCA string set is executed or cancelled, all other orders with the same string will be cancelled. -- Elliot
Started by Elliot Lee @
twsapi: Looking for a complete guide/consultancy on setting up a conditional order
Hi there, I have written a program that meets some of your requirements. http://bullhaven.tripod.com/TradeExecutor/TradeExecutor.htm todd --- ibwin2k <ibwin2k@...> wrote: __________________________________________________ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com
Started by Todd Turner @
VB and ActiveX....updateExtended() Method???? 3
Anyone know if the updateExtended() method is still part of the ActiveX/VB? If not, how does one implement the extended order properties such as tif, oca, and transmit? I am new to programming and just trying to work my way through this stuff. Any help is appreciated.
Started by mickjenks @ · Most recent @
Looking for a complete guide/consultancy on setting up a conditional order
Hi guys, I am a new IB user, a futures daytrader and have no idea on programming. After looking the simple user guide from IB website, I can do nothing with those sample spreadsheets. I post here to see if any expert here could help me to set up a conditional order and to re- organize TWS presentation. A reasonable amount of consultancy fee will be given. (Price could be referred to similar projects on those online auction website,like RentACoder). Here are the requirements: Futures only, less than 10 symbols from different Exchanges, any type of APIs is Ok (reliabity & speedy are the most important) Within a SINGLE PAGE, in addition to general features as TWS, like Order Status, Account Info, Execution Info, contract Description & Market Data, the most important is, allowing a Conditional order with 2 order types: a Buy/Sell market order, Stop Order with aux. price which is based on avg. Buy/Sell prices, default order sizes are allowed for different symbols. My idea is, Single page to see all info I want, and single click/hotkey to complete in/out, (of course, if cancel/modify, extra key is needed) Anyone interested, please reply here or email to me at ibwin2k@.... Thanks in advance. Regards, Char.
Started by ibwin2k @
VB: Get Open High Low Close as Project
Re Posted the Get Open High Low Close BAS Module as a project. There was an minor error in the code. Sorry for the double posting. Next time I will take more time to beat on it before I post it. Download from the files section here if interested: http://groups.yahoo.com/group/twsapi/files/GetClose.zip Scott
Started by marinindextrader @
Current Image
Image Name
Sat 8:39am