i put code into print and get
Print("timecurrent=",TimeCurrent(),"----strtotime 11:45=",StrToTime("11:45"));
if(TimeCurrent()>=StrToTime("11:45")) Print("TimeCurrent()>=StrToTime(\"11:45\")");else Print("TimeCurrent()<StrToTime(\"11:45\")");
//2008.10.02 16:15:55 _a GBPUSD,H1: TimeCurrent()>=StrToTime("11:45")
//2008.10.02 16:15:55 _a GBPUSD,H1: timecurrent=1222967738----strtotime 11:45=1222947900
so wat problem?
u say diff types in comparison, but timecurrent and strtotime both typed datetime, guess not understand
fwiw, anyways, they just 32bit ints like normal ints.
maybe above help..
Best
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I use TimeCurrent()>=StrToTime("11:45") to see whether current time is after 11:45am, but it return different types in comparision.
It got the same result when I use TimeCurrent()-StrToTime("11:45")>=0
Thanks for your help.