Announcement

Collapse
No announcement yet.

Exchange time wise data

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Exchange time wise data

    In Developer reference, it is mentioned that for history request, if we put( -1,-1) as start time and end time parameters, we'll get data of only between 9:30 and 16:00. But after placing same values in that function, I'm getting history data for whole day. I'm attaching some sample code where I'm not getting correct data.



    int handle = eSignal.get_RequestHistory(

    imInstrument.GetSymbol(this.Name),

    ((int)(barSize / 60)).ToString(),

    barType.btDAYS,

    (int)(datetime2 - datetime1).TotalDays,

    -1,

    -1);





    Where datetime1=1/9/2006 and datetime1=28/9/2006.


    My requirement is only between 9:30 and 16:00. Is this function usage changed?

  • #2
    As specified in the documentation, interval of -1, -1 would give you history during "trading hours". To get specific history between 9:30 and 16:00, you can use:

    9x60+30 = 570
    16x60 = 960

    for interval.

    Comment

    Working...
    X