MQL4 and MetaTrader 4 - page 89

To post a new topic, please log in or register
resident card
Hello,  I have some trouble with MQL4's structures. I tried to write a code with structure and I took as example the following: https://docs.mql4.com/basis/operations/other#operation_dot   struct SessionTime     {      string...
HI, there is a function called fileisexist, but if i need it to search on a subfolder of \\files, for example \\files\\foldera, how can i do that? bool  FileIsExist(   const string  file_name,       // File name   int           common_flag=0    // Search area  - It's possible to choose subfolder for...
  spread value (4)
Hi, one question, if I have the spread value in these terms int spread_value = MarketInfo("EURUSD",MODE_SPREAD); which is the most correct way to convert 5 into 0.00005 for example?
Hello, I tried to search this topic, but I can't find anything in the forum.  My question is very simple. I'm developing an EA and I would like to store some informations in a permanent way (i.e. to prevent Mt4 crashes or pc shutdown) . I heard about GV, but my EA should works on different symbols...
  Crossover 2 MA (12   1 2)
i write a code in meta trader 4 it open orders for buy and close , i have one problem that when any order hit Take Profit or stop loss it open another order auto what i need that when order finish stop till next  crossover. i hope to help me guys.
Is it possible to get price data of an OBJ_PITCHFORK at a given bar index? I used ObjectGetValueByShift(), but it doesn't give any useful result (0). ObjectGetValueByShift's documentation says: Applied to trendlines and similar objects. A pitchfork is actually 3 parallel trend lines. So, why...
I’ve downloaded Meta 4 app onto my iphone. I can’t seem to set up more than the one main chart profile. Is it possible to set up more than one chart profile using either meta app 4 or app 5? If so how?
Hello everyone, I am quite new to MQL programming, but I am basically reading through every tutorial I can find these days. However, now that I have a version of an EA, I noticed it does not work as anticipated. Right now I have no idea why this is the case, so maybe someone can explain where I went...
Hi guys, The function works well with just one symbol but once adding the EA to more than one, the function becomes unable to select the pending order to be deleted. I can't find the problem why it doesn't work with more than one symbol. Thank you. void PODelete()         {               int...
Hi All, Completely new to MT4 and looking for some help coding a simple price cross over a moving average. Pseudocode looks like this: __________________ When CurrentPrice crosses MA(100) Start Buy function __________________ Hope you can help!
Hi, I am approaching this programming language for the first time. I currently have an indicator that generates very reliable arrows. I would like to create a strategy that can intercept these arrows. The indicator uses buffer 0 to buy and 1 to sell. I've read that i should use the iCustom function...
Hi, Looking form support from experts to get me  MTF_Stochastic Alert   Mt4 indicator modified to "all time frame MTF_Stochastic Mt4 indicator".  MTF_Stochastic Alert  Mt4 indicator is attached. Regards Rajiv (rajivrodestocks at gmail dot com)
How do you code "Allow live trading"? Thanks in advance.
Hi all, In tradingview there's an indicator called "Correlation coefficient", which represents the correlation between 2 Symbols (the chart symbol and another chosen symbol). See image attached. It ranges from -1.0 to +1.0 . If positive means the 2 symbols move in tandem, else they are moving in...
i want these level notify me: extern bool Base=true; extern bool Entry1 = true; extern bool Entry2 = true; extern bool Premature_Entry_1 = true; extern bool Premature_Entry_2 = false; extern bool Pullback = true; extern bool BreakOut = false; extern bool TP1=true; extern bool Ext_TP1_1 = true;...
I am working with a FX brokerage and we are looking to integrate our Salesforce platform with Metatrader to create accounts as someone signs up for the brokerage. Is anyone familiar with how this can be done. Thanks!
Is  Metatrader API service free or paid? how to get API service?
Hello, I want to create a website like myfxbook, I want to ask you some things about API mt4Can mt4 provide realtime transaction data?does mt4 provide transaction data via the API of people who have login in mt4?thanks.
This is a follow up to the recent article Be In-Phase by Mikhail Korolyuk. As my comments would be too extensive to add there and the topic is (as I think) of general interest, I decided to start a new thread here. This is to be seen also as a attempt to contribut something to the MQL4 community, as...
I think metatrader 4 is all a trader will ever need, as metaquotes will try to end it, i found a way to keep it forever, using offline charts, i see that period converter open a hst file and just refresh it every 2 seconds, on offline chart, my question is how to  instead of use hst file, use a csv...
Hello MQL please give a feedback on this Indicator it calc pivot point and R1 and S1 using the standard method and this method this method is simple math :  EURGBP*GBPUSD=EURUSD , EURJPY/USDJPY=EURUSD ... #property indicator_chart_window#property indicator_buffers...
I'd like to take a break when I lose my deal. I've made a code, but it doesn't work properly. I'd like to put it in terms of purchase. Can you explain the above code? extern double initial_Lots = 0.1; //+------------------------------------------------------------------+//| exter...
Hi, I read about the new mql4(Build 600+) and already updated my EAs, now i have a question. How secure is the new protection against crackers and other types of executable cracking and modifying the code. EX: hex editing date of expiration, memory dumps, etc.. How secure is a simple time...
Is it possible, by code, to retrieve the EA name?
hi, i need help to change parts of some datetime value, with another variable, it's possible to do that?//+------------------------------------------------------------------+//|                                                test.mq4 |extern datetime time= D'2017.11.05 0:01:00';int a=10;int start...
Hi I am wanting to backtest both weekly and monthly timeframes, but MT4's strategy tester only goes as high as daily. Is it at all possible to backtest higher timeframes? cheers honkin
When using the following code in a script, it works fine: CurrentFileName = StringConcatenate(ReportsDir,"\\",title," ",TimeCurrent(),".html"); h = FileOpen(CurrentFileName,FILE_WRITE); However, using the same code in an expert advisor result in an error opening the file. When removing the...
Does anyone know how to calculate the max draw down on a pair at a given bars e.g 100 bars?