Skip a day
-
Hi all. I have a bot that will set pending orders on hour after London open on the US 30. The problem I have is that I sometimes want to skip a day (for example when the UK is on holiday and the US is not. How would I write a block that for example would run on April 18th 2023 and not run19th of April 2023 and then resume on the 20th of April 2023. I have tried all time, filters, month day etc and searched all the forums however I can seem to get this going. Can anyone give me some advice?
-
You can do if you are going to add the date manually, condition block date =! xxxx.xx.xx you need a constant that you can change the date in
-
Thanks for the reply. I am still struggling to get this to work. Would you please take a look at my project? I have created a condition called test condition called testcondition and created a variable with the date however it still trades this day.
shared/vdnKGR4Z
Thanks so much for your assistance
-
Sorry this is the full link
-
You need to get the date from custom code, the standard also includes time and probably in seconds, so was always different to your date. Run this on back test so you can see what this code returns: https://fxdreema.com/shared/p1K7AdsLb
-
That works. Thanks so much.
-
Your welcome