datetime dtDateTest = D'2004.01.01 00:00';
dtDateTestPlusOne = dtDateTest + ??????? ;
Hello, I was wondering if any one could assist me in completing my code. I need to convert a double to a datetime value.
datetime Buy_Exp(double numberbars_buy) //** Double to time??
return iTime(Symbol,MTF,0) + numberbars_buy*MTF*60; // Format conversion?
The purpose of this code is to enable a pending order to expire in a certain number of bars.
I have tried converting both the datetime value and the double to string values and then to add the values and then to re-convert the string back to a datetime value but it was not successful.
Except that that may not be a trading day, e.g. week end.