Forum

MQL4 : TimeDaylightSavings() - How it works ???

Hi coders, int DLSSec= TimeDaylightSavings() ; I'm a trader in Asia country, the forex market open local time is either 06:00 or 05:00 daily (broker's server time = 00:00). It is in winter period right now, the DLSSEc output = 0 and the forex market open local time is at 06:00. I checked with 2 AI

Free AI Chatbots that Good in MQL4 & MQL5 Coding with Unlimited Pic/File Upload

Hi everybody, I used DeepSeek (DS) yesterday to request a simple script.mq4 codes, DS provided me nearly 100 versions of scripts but all versions are NOT working at all, it took me about 5 hours. I kept on asking modifications and corrections, but the DS finally turned up to be "server busy" to

Indicator Not Updating / Repainting Automatically, How ?

Hi coders, I'm learning programming now to develop a simple Stochastic indicator . I don't know what codes are lack of resulting the indicator wasn't updated automatically. Upon a New Bar is launched, there are 2 issues :- 1) Stochastic "< 80" or "> 20", the DotLine wasn't removed automatically 2)

Help to Advise "k+=2" and Remove "Case" Codes

Hi coders, need your advice for codes. I have a Multi-Symbols EA and for exit section, the codes are as follows :- bool SequenceBreak=false; if (OrderType()==OP_BUY && OrderMagicNumber()==mnBUY) { string ExitSequence= StringSubstr (ExitSig(sym,cTkt,cOpTm,cOpPx,cLot,cTPPx,cSLPx), 12 , 12 ); //

Get iTime Automatically for Other Respective TF's Datetime

Hi coders, please advise how to get the iTime automatically for other respective timeframe's datetime ? datetime iTm= iTime (sym, PERIOD_M1 , 15 ); // Shift=15 Print (TimeToStr(iTm)); // Output : 2025.02.14 18:57 Note that the above example of "PERIOD_M1" is not fixed, I may use

Issue on Getting Smaller TF's Shift from Higher TF Bar0

Hi Coders, kindly help. My mission is to get H1's Bar Shift Number (Smaller TF) based on Higher TF's Bar0 for D1 and W1. int H1D1Sf=iBarShift(sym, 60 ,iTime(sym, 1440 , 0 ),true); if (H1D1Sf==- 1 ) H1D1Sf=iBarShift(sym, 60 ,iTime(sym, 1440 , 0 ),false)- 1 ; int H1W1Sf=iBarShift(sym, 60

Tomorrow is Trading Day or Off Day ? How to Tell ?

Hi everybody, I used to basket close all the open trades on Friday 23:30 automatically by setting TimeDayOfWeek(TimeCurrent())==5 in my EA. The problem now is what if today is Thursday and tomorrow Friday is a holiday (off-trading day), is there a command to detect automatically whether a broker's

Which Symbol to Trade for "TODAY" ?

Hi everybody. I always face losses with symbols that ranging for "TODAY" and can only make profits with symbols that volatile for "TODAY". I'm finding ways to forecast / filter only the selected "volatile symbols" to trade for "TODAY" and to avoid those ranging symbols ... What I can think of is as

How to Deal with Bar0 ?

Hi coders, I have a technical issue that I cannot resolve it. I have an entry condition as follows :- double Hi0= iHigh (sym, 60 , 0 ), Hi1= iHigh (sym, 60 , 1 ), Lo0= iLow (sym, 60 , 0 ), Lo1= iLow (sym, 60 , 1 ); bool BuySignal= ... && Lo0>Lo1 && ...; bool SelSignal= ... && Hi0<Hi1 && ...; To

Cannot Get 2nd OrderOpenPrice(), Please Help

Hi coders, I need your help for my learning process. I'm using a Multi-Symbol EA which it can run sizeable pairs and it was written by someone else. My Mission :- 1) To get the 1st OrderOpenPrice 2) To get the 2nd OrderOpenPrice 3) Finally, get the difference MathAbs( 1 - 2 ) I have written the