Forum

Is this a typo in the MQL4 docs? (ArrayResize)

With the frequent memory allocation, it is recommended to use a third parameter that sets a reserve to reduce the number of physical memory allocations. All the subsequent calls of ArrayResize do not lead to physical reallocation of memory, but only change the size of the first array dimension

CAppPanel: Why doesn't Destroy() with reason > 0 not delete the panel?

I'm writing a dashboard that displays information from symbols across all other open charts. If a chart is deleted or added, I need to resize the dashboard and remove/add the missing symbol/timeframes. Rather than coding a resize, I figured it's better to just delete the panel and re-create it

I'm not receiving notifications for replies to my forum comments

For what it's worth, people are quoting me in the replies, but I never receive a notification. I do, however, receive notifications if they mention (@) me by my display name. Here are my notification settings

Retrieving current history data from symbol that doesn't have an open chart on a particular period

As you might know, whenever you call something like CopyRates or iHigh on a Symbol that doesn't have an open chart set to that Period, you will either get old data or an error value. However, MT4 will update the history data for that Symbol + Period and it can be accessed shortly thereafter. My

Using Standard Library -> ChartObjects on Scripts - any way to prevent object deletion?

When using the Standard Libary to create ChartObjects, the objects are deleted upon calling the CChartObject deconstructor. Normally, this isn't a bad thing with indicators/experts/panels, or can be worked around if you call the Save/Load functions, but scripts are a run-once ordeal, so this won't

Is there a way to block a user who is spamming friend requests?

No matter how many times I deny the friend request, it'll always show up again. I tried searching but couldn't find an option for it. The most relevant thing I could find is that this is prohibited behavior

Is it better to use iTime/iHigh/etc instead of Time/High/etc in order to ensure forward compatibility with MQL5?

In MQL4, we're taught (for example) to use Time to access the array of datetimes for bars in the current period, and iTime to access the time of a bar for periods other than the one the user is currently looking at. However, in MQL5, there is no Time array, so we're forced to use iTime. This creates

BUG REPORT: Improper display of the same color between different objects

Video demonstration: https://i.imgur.com/ee1JSo8.gif Issue: the color C'34,34,34' (and similar dark colors within that range) display differently on OBJ_BUTTON compared to other object types. In the video, the OBJ_EDIT is also using C'34,34,34' as the background color that the OBJ_BUTTON uses in the

Should MetaQuotes offer official support for VS Code?

I don't know about you guys, but I'd love for their to be official support for VS Code. It's clear that VS Code is superior to MetaEditor, but there's certain things that MetaEditor does that makes life easier for MT4/MT5 programming. What's currently lacking on VS Code (to the best of my knowledge)

(SOLVED) Using the same enum in two different #include files

Let's say I have a main file (main.mq4) and 2 include files main.mq4 file looks like this: #include <include_a.mqh> #include <include_b.mqh both include files have the same enum defined, say enum FirstName { John, Mary }; When I try to compile the main file, it throws an error saying that the