Suminda Dharmasena
Suminda Dharmasena
Suminda Dharmasena
Added topic How to declare a static dynamic array?
I have: class C { public :    static C c[]; }; C C::c = {}; // Dummy initialiser as initialising is compulsory This is not correct syntax.  I want to figure out how to correct it
Suminda Dharmasena
Added topic [Bug] Stubs of Deleted Projects Appearing in "Shared Project"
There is a long deleted project but the name keep appearing in my "Shared Project" folder. This shows ups as an empty folder. In the pop up "Update from Storage" is not disabled. When I click that I get: 2023.03.26 21:39:58.519 Storage Could not
Suminda Dharmasena
Added topic Checksum '......................' in rep-cache is beyond HEAD
I am getting an error on a Shared Project . How can the above errored fixed? Since I am getting the error on the MQL5 IDE, I have tried checking out the project using Tortoise SVN, updating it and committing it back but this did not solve the error
Suminda Dharmasena
Added topic When Running CopyTicks from an EA no data is returned
When running CopyTicks ( Symbol (), ticks_array, COPY_TICKS_ALL , 0 , 2000 ); from the OnTick() function of a EA the return value is 0 and no ticks are returned even when the function is retried 3 times when no data is returned. The symbol is
Suminda Dharmasena
Added topic Issue accessing values of indicator buffers using CopyBuffer for indicators of type DRAW_COLOR_CANDLES
#property tester_indicator "HAPrice.ex5" #define LOOKBACK_LENGTH 10 #define ORDER_LOOK_BACK 2 //--- input parameters input double    Length              = 30 ; input int
Suminda Dharmasena
Added topic Error = 4756 - ERR_TRADE_SEND_FAILED: Trade request sending failed, RetCode = 10017 - TRADE_RETCODE_TRADE_DISABLED: Trade is disabled
When are times that trading get trade disabled in back testing. The order details are as follows: Trade action: TRADE_ACTION_DEAL Trade symbol: EURUSD Magic number: 0 Order ticket: 0 Order type: ORDER_TYPE_BUY Order filling: ORDER_FILLING_FOK Order
Suminda Dharmasena
Added topic What is ORDER_PRICE_CURRENT?
If I open and pending order and then modify the price is this modified price reflected in  ORDER_PRICE_CURRENT ? Or is this the current market price? Asking to be sure
Suminda Dharmasena
Added topic Modify Volume of a Market / Position Order
Can the volume of a market or position order be modified
Suminda Dharmasena
Added topic Receive Mobile Code for Sri Lankan Number
I am in Sri Lanka (+94). I am not receiving any code when I try to register my number. 
Suminda Dharmasena
Added topic Understanding Valid Order Parameter Combinations
I tried sending an async order with the following parameters: ------------RequestDescription Trade action: TRADE_ACTION_PENDING Trade symbol: EURUSD Magic number: 0 Order ticket: 0 Order type: ORDER_TYPE_SELL Order filling: ORDER_FILLING_RETURN Order
Suminda Dharmasena
Added topic Half Trend Indicator Calculation Formula and Concept
Hello, I have been looking for the formula on how the Half Trend Indicator is calculated but could not find it. What is the formula and concept behind it? S
Suminda Dharmasena
Added topic MQL5 Compensated Summation - Kahan Babushka Neumaier Summation and Fast2Sum Implementation
I am looking for a accelerated compensated summation implementation in MQL. Any pointers? There is a c/c++ implementation but it uses compiler specific extension: #include <cstddef> #include <cstdint> #if defined (_MSC_VER) #include
Suminda Dharmasena
Added topic Compiler Warning "indicator buffers amount is less than needed"
Why as I getting this error? Is it because: #property indicator_buffers 6 #property indicator_plots    2 But I have: #property indicator_type1    DRAW_COLOR_CANDLES and #property indicator_color1    clrRed , clrGreen So
Suminda Dharmasena
Added topic How to draw multiple colour index bar or candle plots in one graph
I am trying to have a candle plot along with a line chart. The properties I have set us is:  #property indicator_chart_window #property indicator_buffers 6 #property indicator_plots    2 #property indicator_label1    "candle"
Suminda Dharmasena
Added topic Please implement inline, __inline and __forceinline
I belive MQL has the inline, __inline and __forceinline keywords but does not inline functions just yet. It is very much desirable that these keywords are actually implemented. Another desirable addition is  constexpr
Suminda Dharmasena
Added topic Reversing a Position in Hedging Mode Gives Invalid Volume When Used With The Position ID
Say I have a long position of 0.01 which I want to reverse hence I sell 0.02. I sent the an opposite order with the position ID so as to have the reversed position also to have the same ID. I get invalid volume error.  How do I rectify this
Suminda Dharmasena
Added topic Creating New Library - 2022.03.30 13:23:05.013 Storage project 'Utils' with the same name already exists
I am trying to create a new project . I had a project call Utils some time back. I deleted it and want to create a new project with the same name. But I am getting the following error: 2022.03.30 13:23:05.013 Storage project 'Utils' with the same
Suminda Dharmasena
Added topic Add to WinGet
Can MT4/MT5 be added to WinGet ( https://github.com/microsoft/winget-pkgs ) so it can be installed and updated from the WinGet cli. This will be very useful in setting up VPS
Suminda Dharmasena
Added topic How to know if the stop price has been reached in StopLimit Orders
I believe a StopLimit order has 2 components Stop price and Limit price I want to know if the stop price has been reached or not. If it has, what elements of the orders has changed. E.g. Can the StopLimit be modified and how? As this is not a limit
12