|
#property copyright \"Copyright ?2007, 520FX Corp.\" #property link \"520fx\" #property indicator_chart_window extern int Cnt=3; extern int Start=3; extern int Stop=22; double O,H,L,C; int CCnt,OCnt; //================================================== void GetKData(int i) { datetime OTime=StrToTime(TimeToStr(TimeCurrent()-i*24*60*60, TIME_DATE) + \" \" + Start); datetime CTime=StrToTime(TimeToStr(TimeCurrent()-i*24*60*60, TIME_DATE) + \" \" + Stop); OCnt=iBarShift(NULL, 0, OTime,false); CCnt=iBarShift(NULL, 0, CTime,false); O=Open[OCnt]; C=Close[CCnt]; H=High[iHighest(NULL,0,MODE_HIGH,OCnt-CCnt,CCnt)]; L=Low[iLowest(NULL,0,MODE_LOW,OCnt-CCnt,CCnt)]; } 程序中的其他部分还勉强可以看懂,但这个不怎么理解,请BULL老师作注释,拜谢。 |
EA入门学院