Keyboard Shortcuts
Likes
- Twsapi
- Messages
Search
Re: C++ vs. C#.NET vs. VB.NET
KBryan
Thanks for your e-mail. I will be out of town for 3 days and will respond
after returning. Please direct future e-mails to???????????
kybryan@...??????????????
thanks
toggle quoted message
Show quoted text
marinindextrader wrote: ?I transfered this question to the VB message board I haunt. |
Re: Resources: Two Excellent Sites For Code and Help
KBryan
I am out of town for 3 days will respond after returning. Please direct
future e-mails to??? kybryan@...???????????????????
thanks
toggle quoted message
Show quoted text
marinindextrader wrote: ?Both of these sites are highly recommended. They have been addded to |
Re: java developer willing to lend a hand
dtkamp
Hi StatTrader. Your view here sounds quite reasonable for someone who
is actively writing Java code. Having already stated a counterview, others are free to decide for themselves, and I'll resist getting any deeper into this complex issue unless/until it becomes something that needs resolving (such as in some sort of cooperative endeavor). Peace. (MS also appears to be planning on bringing some form of Java back to .NET, which will further confuse the discussion.) --- In twsapi@y..., "thestattrader" <TheStatTrader@y...> wrote: True, Java GUI development used to require quite a bit of work-had many problems. True, it's cross-platform nature brings it's owna- days are generaly based on the developer's experience. I've donethe 3-d graphics engine for EverQuest. And the major firms on wallstreet are big time java shops. |
Re: java developer willing to lend a hand
thestattrader
True, Java GUI development used to require quite a bit of work-
arounds when SWING was new. But that was a few years ago. I'm not primarily a GUI guy - I mostly do "mission critical" server side programming, but when i do venture back into SWING work I haven't had many problems. True, it's cross-platform nature brings it's own headaches with it. I personaly can't recall any TWS problems that were Java based, nor can I imagine any limitations it would introduce outside of integration to outside apps via the OS (granted, this may be a primary requirement to some). But any speed or graphics issues now-a- days are generaly based on the developer's experience. I've done professional c++, vb, delphi, and cobol work - and I'm at a loss as to why one would think Java was not suitable platform... java's weakness is in advanced mathemtics, and even then it was used for the 3-d graphics engine for EverQuest. And the major firms on wall street are big time java shops. |
Re: C++ vs. C#.NET vs. VB.NET
marinindextrader
I transfered this question to the VB message board I haunt.
Here is a response from one guy there: Re: C++ vs. C#.NET vs. VB.NET ---------------------------------------------------------------------- ---------- In .NET, pretty much all the languages are on equal footing. I think VB is at a disadvantage with some of the OO stuff, though. I don't think it has function overloading, which is extremely useful, and I'm still not sure how much inheritance it allows. I could be wrong on these, though. I haven't used VB.NET at all. 90% of code or more will be almost exactly the same with VB and C# because of the shared framework, which is where almost everything in .NET comes from. It basically comes down to whether you want to use curly braces or not. The difference in the two is that small. I haven't looked too much into C++, and I haven't seen much documentation on C++.NET at all. In my opinion, C++ is useful for three kinds of developers: 1) Ones who find that speed isn't satisfactory in other languages 2) People who need low-level access to the system 3) Gluttons for punishment. :) Chris --- In twsapi@y..., "dtkamp" <dkamp@e...> wrote: In recent thread on IB board, Kent commented that C++ was the wayto go for creating serious apps. Is this really true any more ifyou're starting from .NET, where all of its languages are based on samea killer trading app, does it really matter much whether you're using |
Resources: Two Excellent Sites For Code and Help
marinindextrader
Both of these sites are highly recommended. They have been addded to
the Bookmarks section for future reference. VB Explorer: The VB Explorer site has very active excellent message boards with very helpful people. Planet Source Safe: The Planet Source site has an excellent searchable code base. Submissions are rated. Planet Source is the largest public code database on the internet. Scott Owner |
C++ vs. C#.NET vs. VB.NET
dtkamp
In recent thread on IB board, Kent commented that C++ was the way to
go for creating serious apps. Is this really true any more if you're starting from .NET, where all of its languages are based on same underlying runtime lib.s and architecture. For purposes of building a killer trading app, does it really matter much whether you're using VB.NET or C#.NET or C++? And can't you just mix in legacy C and C++ lib.s as necessary? |
VC++ SocketClient: Bug in connect?"
Todd_A_Turner
Hi all,
I have seen this problem in both my code, and in the testsocketclient program. If I call eConnect once, and it fails, the next time I call it, an exception is thrown. Anybody know how the connection process is supposed to work? (ie do I need to create a new ewrapper and esocketclient each time I try to connect, or can I reuse?) thanks |
Re: IB Post Questions answered & Q for Dkamp
marinindextrader
Worth Repeating:
"goldensilvermana": "It is the little guy against the big boys and I smell blood. The problem is that there are many lone wolves running down rabbit trails and that is not the solution" --- In twsapi@y..., "goldensilvermana" <kybryan@c...> wrote: Dkampthey want solved.interested parties.for the design costs.format that would give the group input.the team and be in charge. There cannot be mob rule, but activethese positions.after system analysis and design is completed. Owners will be expected toand coding.we will move the dialog from the public forum to a secure system forhave people that I have worked with on projects that are reasonable costgo that path but what I propose is organization and structure andpeople that work well within the team environment. We need a place to postto make a commitment in cash and or sweat please email and or postA Q for you. Would the elite trader link thread help the quest? I see |
Re: java developer willing to lend a hand
simgenie
I don't trade options but writing a separate (must be separate or in
another thread because of blocking) program to send keystrokes (enter) or mouseclicks to a window at a predefined spot isn't that complex. I don't know what the options window looks like (I don't trade options) or if the "no" button defaults (rendering a simple enter keystroke unusable). The basic concept is to figure out the unique qualities of the popup window you are searching for (if any) by using a program like Microsoft's SPY++. Then when the window you are looking for appears you either send a set of keystrokes to the window or a mouse click to the correct spot to kill the window. The program that does this should probably only have one function - to kill the dialog, and should just sit there looping, waiting for that dialog to pop up and then it zaps it. I do this for the ActiveX "Accept Incoming Connections" dialog so that my program can log into TWS without any intervention on my part. --- In twsapi@y..., "qnolte" <q1@n...> wrote: The option confirmation requirement is a real problem for me also.I didn't realize that the real problem is the option exchangesrules. Can anyone come up with a screen scrapper that could see the popupit's IBthe option exchanges that don't allow automated option trading - is just following their rules.it |
IB Post Questions answered & Q for Dkamp
goldensilvermana
Dkamp
Here is how I envision a workable solution: (1) All interested parties need to make a list of what problems they want solved. (2) These problems need to be listed then voted on by the interested parties. (3) Their needs to be an agreement on what problems there will be solutions for. (4) We need a group of people that will meet the financial requirements. By meet I mean a small group with large pockets or a large group that can kick in $50 to $100. What ever it would take for the design costs. (5) There would have to be some organization structure and or format that would give the group input. (6) A lead designer will have to be given the authority and be in charge to make the decisive final necessary decisions to move the project along timely. (7) A committee and or board would be formed that would represent the team and be in charge. There cannot be mob rule, but active participation will be encouraged. Professional people will hold these positions. (8) Legal documents will be signed. All paying members will own a stake in the software. Owners will pay cash upfront and receive receipts and documentation. (9) Initial cash will pay for professional system analysis and design. Programmers will be determined by bid and or selection after system analysis and design is completed. Owners will be expected to come up with monies for final coding of project. (10) Resumes and references will be required to select members that will be actively participating in the system analysis and design and coding. (11) Coding will be compartmentalized to ensure software ownership security. (12) As soon as we come up with the cash and a competent team then we will move the dialog from the public forum to a secure system for development. I estimate about $10,000 to complete a design, but that may change with the amount of interest and the bells and whistles wanted. I have people that I have worked with on projects that are reasonable cost wise and very competent to execute what this project would entail. Bottom line there is over 124 members and interested parties on the Yahoo spin off thread since this thread was first posted. It is the little guy against the big boys and I smell blood. The problem is that there are many lone wolves running down rabbit trails and that is not the solution for everyone. There are those that will always go that path but what I propose is organization and structure and people that work well within the team environment. We need a place to post resumes. Everyone welcome those with just cash and also those with IT skills and cash. If you are interested in being part owner and would like to make a commitment in cash and or sweat please email and or post Thanks dkamp for the questions, I will be out until Thursday night. A Q for you. Would the elite trader link thread help the quest? I see that you frequent there. |
Re: java developer your hired contact IB
goldensilvermana
--- In twsapi@y..., "thestattrader" <TheStatTrader@y...> wrote:
about me: I'm a professional java developer with over 9 years ofbut now I mostly trade options for time periods ranging from 1-3 weeks.Looks like you voluntered to me :) we really need to crank the heat up on IB. I vote you contact them for the group and I am sure you will get backed up by everyone. Let us know what there response is. Thanks Kent |
Re: java developer willing to lend a hand
dtkamp
If that's it, I'm not concerned, as the Java interface I'm planningSorry for misunderstanding. I'm not aware of any problems with IB's Java API, although I've asked them questions about whether the APIs are kept in synch, and whether they are paying preferential attention during their own development to one or the other of the APIs, but did not get an answer. It would be nice if someone could answer those questions, as well as questions such as whether they will be dropping APIs for which there is not sufficient interest. Could save some of us a lot of trouble in the long run. |
Re: java developer willing to lend a hand
You mentioned "limitations we see in the Java-based TWS." Your
toggle quoted message
Show quoted text
comments are about GUI programming in Java. I'm looking for problems with the TWS Java API. Is this what you are trying to say? "If you write a GUI trading program in Java, it's going to suck in the same ways that TWS does." If that's it, I'm not concerned, as the Java interface I'm planning does not have a Java GUI. --- In twsapi@y..., "dtkamp" <dkamp@e...> wrote:
--- In twsapi@y..., "kgeis" <kgeis@y...> wrote:Please comment on the Java limitations. I've heard nothing of theHi Ken. Right, I would put performance issues at the bottom of the |
Re: java developer willing to lend a hand
dtkamp
--- In twsapi@y..., "kgeis" <kgeis@y...> wrote:
--- In twsapi@y..., "dtkamp" <dkamp@e...> wrote:Hi Ken. Right, I would put performance issues at the bottom of the list of limitations. This is a huge topic to start a discussion about, but will outline a few points broadly. BTW, I don't have anything against Java or the notion of Java, having worked with it for a couple of years. - Lots of bugs, which are very difficult to work around, often leading to use of platform-specific native code or tweaking and recompiling SUN's code that one shouldn't really be touching. (I think our list at one point had grown to something like several hundred Swing bugs that we had worked around or fixed, although they have addressed many of these in later versions of Swing.) - Unless your apps are fairly simple (which they may well be), the Java UI classes suffer from their need to be cross-platform (i.e., they can't afford to take advantage of many platform-specific features, and hide access to some of the most basic stuff). - Most of the cool Java stuff is finding its way into Microsoft's .NET. Microsoft (like it or not) devours everything in its path. If we're not going to break up this monster, then we can at least avoid getting stepped on it (kind of like trading amongst the investing giants). So unless one is really, really serious about cross-platform development (Macs and Unix), I would personally be really, really hesitant to use Java for a trading app. |
VB TWS: New Sample Project For Newbies In The File Section
marinindextrader
I have posted a sample project that uses MicroSoft Hierarchical Flex
Grid, an in cell editing routine and a better start for someone just getting going. Still a very basic example...but it will help those who are just getting started. Great foundation to start a program with and begin exploring TWS API [CODE] Option Explicit Private Sub Command1_Click() 'call for the connection 'your TWS must be up and running in order to connect Tws1.Connect "", 7496 End Sub Private Sub Form_Load() Dim iTemp As Integer Dim iTemp2 As Integer Dim Cancel As Boolean 'grid formating stuff With hFlexGrid .Col = 0 .Row = 0 .ColSel = .Cols - 1 .RowSel = .Rows - 1 .FillStyle = flexFillRepeat .CellFontBold = True .CellAlignment = flexAlignCenterCenter .TextMatrix(0, 1) = "Symbol" .TextMatrix(0, 2) = "B-Size" .TextMatrix(0, 3) = "Bid" .TextMatrix(0, 4) = "Ask" .TextMatrix(0, 5) = "A-Size" .TextMatrix(0, 6) = "Last" .TextMatrix(0, 7) = "L-Size" .Col = 1 .Row = 1 .ColWidth(0) = .RowHeight(0) + 50 'number the first column and alternate the row colors For iTemp = 1 To .Rows - 1 .TextMatrix(iTemp, 0) = iTemp If Not Cancel Then For iTemp2 = 1 To .Cols - 1 .Row = iTemp .Col = iTemp2 .CellBackColor = &HE0E0E0 Cancel = True Next iTemp2 Else Cancel = False End If Next iTemp 'adds a couple of items to the combo box Combo1.AddItem "Stocks, Instinet" Combo1.AddItem "Futures, Globex, 200206" End With End Sub Private Sub hFlexGrid_DblClick() 'calls the grid editor when you double click a cell Call GridEdit(Asc(" ")) End Sub Private Sub hFlexGrid_GotFocus() Dim strTemp As String If txtCellEditor.Visible Then hFlexGrid = UCase$(txtCellEditor) 'calls the req market data text box loses focus, restricts symbols to row 1 If txtCellEditor <> "" And hFlexGrid.Col = 1 Then strTemp = UCase$(txtCellEditor) Call reqMarketData(strTemp, hFlexGrid.Row) ElseIf txtCellEditor = "" Then 'cancels market data if you leave the cell empty Call cancelMktData(hFlexGrid.Row) End If txtCellEditor.Visible = False End If End Sub Private Sub hFlexGrid_KeyDown(KeyCode As Integer, Shift As Integer) 'cancels the market data if you use the delete key remove a symbol If KeyCode = vbKeyDelete And hFlexGrid.Col = 1 Then Call cancelMktData(hFlexGrid.Row) Else 'just in case....not really necessary hFlexGrid.TextMatrix(hFlexGrid.Row, hFlexGrid.Col) = "" End If End Sub Private Sub hFlexGrid_KeyPress(KeyAscii As Integer) 'calls the grid editor when you start typeing Call GridEdit(KeyAscii) End Sub Private Sub hFlexGrid_LeaveCell() Dim strTemp As String If txtCellEditor.Visible Then hFlexGrid = UCase$(txtCellEditor) 'calls the req market data when you leave a cell, restricts symbols to row 1 If txtCellEditor <> "" And hFlexGrid.Col = 1 Then strTemp = UCase$(txtCellEditor) Call reqMarketData(strTemp, hFlexGrid.Row) 'calls cancel market data if you go in and leave it empty ElseIf txtCellEditor = "" Then Call cancelMktData(hFlexGrid.Row) End If txtCellEditor.Visible = False End If End Sub Sub GridEdit(KeyAscii As Integer) With txtCellEditor 'use correct font .FontName = hFlexGrid.FontName .FontSize = hFlexGrid.FontSize Select Case KeyAscii Case 0 To Asc(" ") .Text = hFlexGrid .SelStart = 1000 Case Else .Text = Chr(KeyAscii) .SelStart = 1 End Select 'position the edit box .Left = hFlexGrid.CellLeft + hFlexGrid.Left .Top = hFlexGrid.CellTop + hFlexGrid.Top - 10 .Width = hFlexGrid.CellWidth - 8 .Height = hFlexGrid.CellHeight - 15 .Visible = True .SetFocus End With End Sub Private Sub Tws1_tickPrice(ByVal id As Long, ByVal tickType As Long, ByVal price As Single) 'populates the grid with the price information hFlexGrid.TextMatrix(id, 2 + tickType) = Format(price, "0.00") End Sub Private Sub Tws1_tickSize(ByVal id As Long, ByVal tickType As Long, ByVal size As Long) 'populates the grid with the size information hFlexGrid.TextMatrix(id, 2 + tickType) = size End Sub Private Sub txtCellEditor_KeyDown(KeyCode As Integer, Shift As Integer) 'handles the little text box editor for certain keystrokes Select Case KeyCode Case vbKeyEscape txtCellEditor.Visible = False hFlexGrid.SetFocus Case vbKeyReturn hFlexGrid.SetFocus Case vbKeyDown hFlexGrid.SetFocus DoEvents If hFlexGrid.Row < hFlexGrid.Rows - 1 Then hFlexGrid.Row = hFlexGrid.Row + 1 End If Case vbKeyUp hFlexGrid.SetFocus DoEvents If hFlexGrid.Row > hFlexGrid.FixedRows Then hFlexGrid.Row = hFlexGrid.Row - 1 End If End Select End Sub Private Sub txtCellEditor_KeyPress(KeyAscii As Integer) 'noise suppression 'If KeyAscii = vbKeyReturn Then KeyAscii = 0 End Sub Public Sub reqMarketData(TWSsymbol As String, trow As Long) 'issue description vars Dim TWSsecType As String Dim TWSexpiry As String Dim TWSstrike As Single Dim TWSright As String Dim TWSexchange As String Dim TWScurency As String 'stock or future for demo? If Combo1.ListIndex = 0 Then TWSsecType = "STK" TWSexpiry = "" TWSexchange = "INSTINET" ElseIf Combo1.ListIndex = 1 Then TWSsecType = "FUT" TWSexpiry = "200206" TWSexchange = "GLOBEX" End If 'options and currency vars TWSstrike = 0 TWSright = "" TWScurency = "" ' must have symbol, secType, and exchange If TWSsymbol = "" Or TWSsecType = "" Or TWSexchange = "" Then Beep MsgBox ("You must enter at least symbol, security type, and exchange.") Exit Sub End If 'calls for the market data Tws1.reqMktData trow, TWSsymbol, TWSsecType, TWSexpiry, TWSstrike, TWSright, TWSexchange, TWScurency 'displays the contract specs if a future hFlexGrid.TextMatrix(trow, 8) = expiryNumToAlpha(TWSexpiry) End Sub Sub cancelMktData(trow As Long) 'cancel the market data Tws1.cancelMktData trow Dim iTemp As Integer 'blanks out the entire row after you cancel the data For iTemp = 0 To hFlexGrid.Cols - 1 hFlexGrid.TextMatrix(trow, iTemp) = "" Next iTemp End Sub Function findSymbolSlot(ByVal symbol As String) As Long Dim lngTemp As Long 'this function selects the right row in the grid With hFlexGrid For lngTemp = 1 To .Rows - 1 If InStr(.TextMatrix(lngTemp, 1), symbol) Then findSymbolSlot = lngTemp Exit Function End If Next lngTemp End With End Function Function expiryNumToAlpha(ByVal strExpiry As String) As String 'this function returns a user friendly formatted version of contract date Dim strTemp As String strTemp = Mid$(strExpiry, 3, 2) Select Case Right$(strExpiry, 2) Case "03" expiryNumToAlpha = "MAR" & strTemp Exit Function Case "06" expiryNumToAlpha = "JUN" & strTemp Exit Function Case "09" expiryNumToAlpha = "SEP" & strTemp Exit Function Case "12" expiryNumToAlpha = "DEC" & strTemp End Select End Function |
Re: java developer willing to lend a hand
--- In twsapi@y..., "dtkamp" <dkamp@e...> wrote:
With respect to Java, I bet you actually get a lot of us avoiding itPlease comment on the Java limitations. I've heard nothing of the sort except for performance issues from people who don't know what they are talking about. Ken |
Re: java developer willing to lend a hand
qnolte
The option confirmation requirement is a real problem for me also. I
didn't realize that the real problem is the option exchanges rules. Can anyone come up with a screen scrapper that could see the popup confirmations and automatically response to them? --- In twsapi@y..., "dtkamp" <dkamp@e...> wrote: "i hear options trigger TWS pop-ups so i can't have ait just because of the limitations we see in the Java-based TWS. Inusing Java (at the cost of cross-platform potential). |
Re: java developer willing to lend a hand
dtkamp
"i hear options trigger TWS pop-ups so i can't have a
true program trading platform in place :(" Hi Jason. You may know this, but for others reading the above, it's the option exchanges that don't allow automated option trading - IB is just following their rules. With respect to Java, I bet you actually get a lot of us avoiding it just because of the limitations we see in the Java-based TWS. In other words, you can get an immediate edge over TWS just by not using Java (at the cost of cross-platform potential). |
java developer willing to lend a hand
thestattrader
about me: I'm a professional java developer with over 9 years of
total software development, 5 years exclusively in java and related technologies. This includes banking systems, dept of defense, and more - very large real world complex systems. I used to daytrade during my down time (few days to few months), but now I mostly trade options for time periods ranging from 1-3 weeks. I've written my own analysis software, etc. After I put on a trade, my primary concern is follow-up strategy when a trade goes wrong. I wrote software to do this as well, as there was a lot of different variables that went into it. I just now discovered that TWS gives a java api, so I'm rebuilding my system and hooking it up to IB. Unfortunately, i hear options trigger TWS pop-ups so i can't have a true program trading platform in place :( if anyone wishes to come to the dark side (java), I'd be happy to help them out :) Jason |