in other way can i convert double to datetime?
In the first place you are not supposed to take a symbol like OBJ_PITCHFORK and use its numerical value in a function call. That makes the code unreadable. Just use the symbol.
ObjectCreate( "andrew1", OBJ_PITCHFORK,0, gt1t,gp1,gt2t ,gp2 ,gt3t ,gp3 ) ;
In the second place, if you are having to convert from double to datetime you are probably doing something wrong.
And finally, if you do need to do it, for some really valid reason then
double val1 = 123.345; datetime stupid = val1;
3ammary:
datetime BarTime = Time[17] or iTime(NULL, 0, 17)
i have for example gt1t=17 in double format,,, it means 17 bars before the current bar
how could i get this bar in datetime format
thanks in advance
thanks alot all i have done it :)

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
the syntax of it is
the main problem is that
gt1t
gt2t
gt3t
need to be converted from double format to datetime format as the function accept it
i have for example gt1t=17 in double format,,, it means 17 bars before the current bar
how could i get this bar in datetime format
thanks in advance