Forum

Multiple interface inheritance - is this coming in the future?

We have interfaces in MQL but they really don't provide much value than just using an abstract base class in my opinion. Interfaces become alive when you can inherit a class from multiple interfaces. interface IIsStringable { string ToString() const ; }; interface IIsWaitable { bool IsReady()

Issue with Optimizer caching previous results. How do you reset it? Video included

I am try to restart an optimization process after I updated the code. Every time I want to run the optimization process from the beginning, the optimizer remembers what iteration it was up to in the previous run, and starts from there again. I don't want this behavior, and I can't see how to disable

Is ORDER_EXTERNAL_ID a user fillable field?

I noticed the ORDER_EXTERNAL_ID in the order properties docs. Docs say: Order identifier in an external trading system (on the Exchange) Does that mean external as in we can input an ID there? If so how can we set this value? This would be helpful to track and group orders that belong to a trade in

Issue with template classes. Can templates be made to accept both reference and value types?

Given an example class below, I would like to be able to use it with values, pointers and structs. This issue is that structs can only be passed by reference which gives me a lot of headaches trying to make my own personal library. See the simple Queue class below which is templated. template <

Calculating smallest possible allowed stop loss using STOP_LEVEL

In a custom trade class I am updating, I just want to detect if the stop loss size is too small and display a helpful message if it is the case. Here is my code, it's custom but self explanatory bool Trade::CheckStopLimits( const TradeOrder &order) const { int currentSLPoints =

Is it possible to prevent mouse left btn down on chart from moving chart sideways for this scenario?

I've got a custom trade setup box built that I want the user to be able to customize with the sliders. The sliders are a canvas obj _topCircle = new CCanvas(); if ( !_topCircle.CreateBitmap(_capi.GetChartID(), 0 , "_btn_box_resizer_1" , _capi.T(middleCandle), _upper.TopPrice(), _canvasSize

How to change buffer color of indicator in OBJ_CHART

When creating an embedded chart... bool EmbeddedChart::Create() { ResetLastError (); if (! ObjectCreate (_chartID,_name, OBJ_CHART , 0 , 0 , 0 )) { printf ( "[%s ERROR]: failed to create the embedded chart object! Error code = %i" , __FUNCTION__ , GetLastError () );

Does anyone know how to fix this annoying events problem in the GUI Library?

In many projects I've come a cross this issue where the events start playing up if you introduce more than one panel. In some cases I would like a dialog popup to change some settings/get user input/display detailed info etc. Please does anyone know the fix for this? Here is a test panel, test env

How to Declare a Template Class (CHashMap) Within My Own Class? - Can't get it to work

Howdy, I want to use the Stdlib CHashMap in my class. However I can't seem to get past the declaration 🤬 class CurrencyIndexPanel : public Leaderboard { private : CHashMap < string , TableRow*>* _currencies; It throws these errors '<' - semicolon expected

Code to Arrange Open Chart Tabs In Specific Order

Is there a way to arrange existing chart open windows via code? I want to programatically have the ability to re arrange the existing chart order around to make sure charts I want to focus on the most, are at the front. I was hoping there was something in chart operations ... but I couldn't see