Hi Guys,i have been doing a bit of coding and have encountered a bit of a problem i would like you to help me on,how do i change the time format to read "15:30:50" instead of showing "15:30" as shown below(i would like the seconds to show as well);
if (PositionsTotal()==0 && OrdersTotal()==0 && (StringSubstr(hoursAndMinutes, 0,5)=="15:30")&&NewBar())
i tried changing the "time_minute" parameter to "time_seconds" on the Timetostring as shown below,;
string hoursAndMinutes =TimeToString(time,TIME_ MINUTES);
i changed the above code to the one below, it still wont work,it remains on "15:30" and not "15:30:50"
string hoursAndMinutes =TimeToString(time,TIME_ SECONDS);
please help.
- How can I set Hours and Minutes as input parameters and use it in my function.
- I will write an advisor free of charge
- HELP - Date Lookup in an external file
- TIME_MINUTES|TIME_SECONDS just like the documentation shows.
-
Please edit your (original) post and use the CODE button (or Alt+S)! (For large amounts of code, attach it.)
General rules and best pratices of the Forum. - General - MQL5 programming forum (2019)
Messages Editor
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