Question about the Genesis API

Discussion in 'Automated Trading' started by Bluegar3, Apr 21, 2008.

  1. Hi,

    I was wondering if anyone could explain to me how I do this. I'm using this callback function where there is a change in the quote..

    int CMyStock::OnGotQuoteLevel1(GTLevel1 *pRcd)

    I have no problem, finding the bid for whatever stock I'm trading. but what I want to do is if I get a call for say WMT, I want to see what the price of another stock is.
  2. gen has no historical data to my knowledge, so you'll have to either subscribe and wait for an update on the new stock or be storing the data in memory or db/file and just check it on the fly.
  3. You probably want to throw your data collection routines in a seperate thread if you are going to collect your own historical data. In very fast markets (after fed), you can run into problems.
  4. I was just thinking there would be an easier way to do this rather than to create an array and have it search through an array each time.

    I know with the 3rd party products out there you can create a stock...

    CreateStock() // constructor
    CreateStock() ---> again


    The problem is that when I create the 2nd stock. I DO NOT want to have calls from the callback functions. I'm not sure how to do this